Yorkshire 274 and 291 for 6 beat Warwickshire 217 and 347 by four wickets
In an encounter of endless twists and turns, the decisive punch in this enthralling Championship match was thrown by Jacques Rudolph and Jonathan Bairstow.
Yorkshire's sixth-wicket pair added 153 in just 27 overs to help their side to a four-wicket win over Warwickshire with more than a session to spare. The second session of the final day produced the most fluent batting of the match as Yorkshire plundered 161 runs in 30 overs to secure just their fifth win since the start of 2008.
The roars of approval that greeted the winning run told their own story. This could prove to be an enormously valuable victory. Both these teams are likely to be weakened by international calls during the summer, so points earned here could prove crucial when the relegation tussle reaches its height.
After three-and-a-half days of wonderfully even cricket, the end came rapidly. Yorkshire's decision to take the attack to the Warwickshire bowling after lunch on the final day produced dramatic results, as the hosts wilted in the face of the assault and the visitors eased to 21 points.
Bairstow (104 balls, 14 fours) was particularly impressive. Compact and well organised, he drove beautifully and cut and pulled powerfully. He fell just three short of a career best and, aged only 20, should have a bright future. His keeping is currently a touch rustic but, on this evidence, he looks plenty good enough to succeed as a specialist batsman.
Rudolph (98 balls, 13 fours) was almost as impressive. There are many who believe that Kolpak registrations such as Rudolph are the bane of county cricket, but the 28-year-old South African has certainly proved a valuable acquisition for Yorkshire. He now averages over 54 in his 49 first-class matches since joining them at the start of 2007 and his calm and class can only have reassured Bairstow.
Rudolph was also a delight from a spectator's point of view (it is meant to be a spectator sport, after all). A deft late cut off the leg-spin of Imran Tahir was a particular highlight, while even David Gower would have been proud of some of the languid drives that Rudolph persuaded through the covers off the same bowler. To have recorded two half-centuries in the game on this pitch was a fine achievement.
Warwickshire will reflect that they allowed victory to come a little too easily in the end. At lunch, with Yorkshire on 130 for 5, it appeared the game had swung the way of the hosts. Though Yorkshire started the day solidly, a spell of three wickets for 12 runs in nine overs appeared to have given Warwickshire the edge.
Shahzad played back when he should have been forward, McGrath's torture at the hands of Imran Tahir ended when he played all round one, while the left-handed Gale edged a googly to slip. Adam Lyth, meanwhile, could count himself somewhat unfortunate to be adjudged caught behind down the legside to end a highly impressive innings.
At that point, Imran Tahir looked dangerous. He isn't exactly a one-club man - Warwickshire is his 17th first-class team - but with his variation, his enthusiasm and his wicket-taking ability, he looks certain to become a favourite in Birmingham. He's already taken more wicket at Edgbaston than either Collins Obuya or Brad Hogg did in their seasons as overseas players.
Perhaps Warwickshire were a bit unfortunate. While the ball moved extravagantly in the morning's overcast conditions, the sun came out after lunch and batting became much easier. The loss of the toss was also important.
But, if they are honest, they will also admit they performed very poorly after lunch. Chris Woakes, so often a beacon of precocious excellence, betrayed his inexperience with a barrage of half-volleys and long-hops, while Neil Carter, Imran Tahir and Andrew Miller also leaked runs. The captain's field placing was also hard to fathom at times and, in the last hour or so, the wheels came off completely.
"We mucked up," Warwickshire's director of cricket, Ashley Giles admitted afterwards. "It was our game to lose but that session [after lunch] cost us. We have to be more ruthless in future.
"Yes, they counter-attacked well, but we let them. We took our eye off the ball. We went chasing the game and bowled a lot of half-volleys. It wasn't just that last session. We could have batted better and we could have taken some more catches but, from the position we were in, we should have won. It's a disappointing loss."
Understandably, Andrew Gale was in far more positive mood. "I might retire now," he joked, as he reflected on victory in his first game as Yorkshire captain. "I couldn't have hoped for things to go any better.
"People have been writing us off all winter, saying that we're going to go down, but we'll use that in our favour. We'll go into every game as underdogs and we'll fight. I was a bit worried at lunch time, but we had a chat and decided that if we were positive, we could get something out of the game.
"We decided that if we just let Imran Tahir bowl - and he is a world-class bowler - that he'd take wickets. Yes, Johnny dropped a key chance, but these things happen. He showed his character and potential today. He didn't beat himself up about it and when Johnny is in that form [with the bat], you don't mind the odd drop."
There was further good for Yorkshire. Tino Best, the former West Indies fast bowler, has now secured a work permit for the season. He's likely to make his championship debut in next week's game against Kent. While he's signed as an overseas player, he could re-register as a Kolpak if Yorkshire are able to find another overseas. The search continues.
Warwickshire, meanwhile, have named the same squad for their championship game at Old Trafford starting on Thursday. Rikki Clarke is fit to play only as a specialist batsman, while Ant Botha will be considered as a second spinner.