Wednesday 12 July 2017 17:38, UK
Somerset, resumed the day on 101-4 chasing 262 to win, and were well-placed after half-centuries for both Adam Hose (68) and Steven Davies (59) before they crashed from 231-6 to 258 all out.
Ryan Sidebottom finished with match figures of 8-115 which included there of the last four wickets to fall to see Somerset suffer an agonising defeat.
The win wasn't enough to see Yorkshire top the table though, as Tom Westley's phenomenal unbeaten century steered Essex to the summit following an emphatic eight-wicket win over Surrey at Guildford.
Westley registered 108 not out from 168 balls while Nick Browne contributed an equally important 77 from only 96 deliveries as Essex made light of a victory target of 253 from a minimum of 83 overs, getting home in 64.2.
Earlier, on a wearing pitch, Surrey had been dismissed for 288 from their overnight tally of 253-7, with Ben Foakes left stranded on 65 against his former employers.
A first Championship five-wicket haul for Stephen Parry and a timely knock from England Test hopeful Haseeb Hameed helped Lancashire wrap up an eight-wicket win against Middlesex at Southport.
The day started with Middlesex 156-6 in their second innings, holding a slender 27-run lead, and while Dawid Malan (52) celebrated a call-up to the England T20 squad with a fifty, Parry removed the tail to finish with 5-45.
Lancashire then eased to their 108-run target for the loss of only two wickets, with Hameed - finishing unbeaten on 38 - sealing victory with a six. It's the defending champion Middlesex's first Championship defeat in 21 games, since September 2015.
In Division Two, Luke Wells led Sussex to a five-wicket win over Leicestershire on the final afternoon of their match at Grace Road.
The visitors resumed on 100-2, chasing 232 to win, and although they lost three further wickets, Wells got them over the line with an unbeaten 90.
Nightwatchman Danny Briggs (14) was the first to fall, but Wells put on 70 for the fourth wicket with Staanie van Zyl (24) to settle any nerves and then guided his team to victory shortly after lunch.
Meanwhile, in Bristol, Gloucestershire batted out the final day to secure a draw against Division Two leaders Nottinghamshire.
Resuming on 30-1 in their second innings - still some 202 runs behind - Gloucestershire were boosted by 71 from Chris Dent and Graeme van Buuren's unbeaten 88 as they reached 254-5 when the captains shook hands.