Luke Wells completed his maiden first-class century as Sussex beat Durham by two wickets in a tense finish.
The visitors resumed the day on 237-4 needing 72 more for victory and looked well set as Wells hit 17 fours in his innings of 103.
But from 277-4 they slipped to 294-8, as Ruel Brathwaite finished with 5-58.
Amjad Khan hit the winning runs as Sussex picked up their first win of the season and Durham were beaten for the first time this season.
Sussex began day three in confident mood and a fifth-wicket stand of 128 between Wells and Ben Brown (61) took them to within 32 of victory.
“It was the slip fielding which eventually proved costly on the final day”
Martin EmmersonBBC Radio Newcastle
Wells - the son of former Sussex and England batsman Alan - had been dropped before he could add to his overnight score of 74 but the first man to go was Brown, as he edged an attempted pull off Brathwaite to wicketkeeper Michael Richardson.
It started a demise of four wickets for the addition of only 17 runs, as Wells soon followed as he was caught at point, again off Brathwaite.
The England-qualified West Indian paceman also got rid off Rana Naved-ul-Hasan, who danced down the pitch only to edge to Richardson.
Brathwaite completed his second first-class five-wicket haul when he trapped James Anyon lbw and Sussex had stumbled to 294-8.
Khan and Andy Hodd held their nerve and scored the 15 more for a victory that had looked unlikely when Sussex trailed by 98 on first innings.
DAY FOUR REACTION
BBC Radio Newcastle's Martin Emmerson:
"They say catches win matches and on a final, nervous morning here, the game could still have gone either way.
"But while Durham will admit their batting let them down in this one - particularly in their second innings - it was the slip fielding which eventually proved costly on the final day.
"Luke Wells was still on 74 when he was dropped third ball of the morning by Gareth Breese. If the chance had stuck things could have been so different.
"Wells eventually made his 100 but was dropped at least five times on the way and when he was eventually dismissed it was all a bit too late.
"Credit to the Durham bowlers today who stuck to their task so well. Claydon, Thorp and Brathwaite were excellent and well done to Ruel for his five-for.
"Durham need to pick themselves up now after this one and prepare for the visit of Warwickshire next week."
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.