Three-time champion John Higgins suffered a 6-5 defeat by world number 16 Mark Davis in the UK Championship despite making a 147 maximum break.
The Scot, 37, struggled for form as Davis moved into a 5-2 lead in their best-of-11 second-round match.
A run of three frames, including a seventh maximum of Higgins's career - and 95th in history - forced a decider.
"No wonder snooker is synonymous with late-night drama. Strangely out of sorts, Higgins found himself 5-2 down but on the cusp of defeat the so-called "Wizard of Wishaw" conjured the seventh maximum break of his glittering career to spark a three-frame burst. When in the decider, he sunk a long pressure red, the remarkable comeback looked complete. But to gasps from the crowd, Higgins missed the final pink and Davis, enjoying an Indian snooker summer at the age of 40, stole the show for what he described as the biggest win of his life."
But Higgins missed a regulation final pink to let Davis back in and the Englishman potted it to clinch the win.
"I'm gutted," said Higgins. "Normally clearing up in the last frame I'd have done it. I didn't deserve to win that match. Who knows where the 147 came from?"
Davis, 40, faces 2003 champion Matthew Stevens in the last eight.
"I was going for doubles and all sorts in the end," said Davis. "It was like the
1985 World Championship final."
Davis said he ranks the win as his best ever: "This is at the top. I've not got a good record against John at all. It's my best result for a very long time."
reached the last eight of a major tournament for the first time with victory over Mark King.
The 17-year-old, ranked 74th, came back from 3-0 down to beat King 6-4 in York and set up a clash with former world champion Shaun Murphy.
"It's amazing, unbelievable, and it was a great match for me," said Brecel, who turned professional in 2011 and got a wildcard to stay on the tour after finishing outside the top 64.
Teenager Brecel shocks King with win
"I was feeling very bad and I wanted to go home, but in the fourth frame everything changed.
"After the first frame I won, I gained confidence. It was an amazing moment at the end.
"I've not really surprised myself with how I've done. I'm still not playing well so hopefully in the next game I can play a bit better. It's good to be here and nearly everyone's supporting me, so that's good.
"People expect a lot from me but I'm only 17, so I have enough time to develop my game."
World number two
beat Ryan Day to make the quarter-finals.
Selby had been in danger of being knocked out as he trailed 3-0, but he recovered to win 6-4.
He will face
in the last eight after the Australian beat Barry Hawkins 6-2.