Somerset 260 (Compton 66) and 133 for 3 beat Surrey 195 (Thomas 4-23) and 197 (Meschede 4-43) lead by seven wickets
Somerset eased their relegation worries by beating Surrey by seven wickets in a dogfight at Taunton.
At the start of the day Surrey lost their remaining six wickets for the addition of 100, four of which fell to Craig Meschede, before Piyush Chawla polished off the innings.
Chasing 133 for victory, Somerset raced to their target in 23.4 overs, as an unbeaten 36 from James Hildreth and Craig Kieswetter's 34 not out saw them across the line with 21 valuable points.
Resuming on 97 for 4, it was Zander de Bruyn who began the day by bringing up the Surrey hundred with three runs off the first ball of the first full over, bowled by Alfonso Thomas.
Steven Davies got off the mark with two boundaries off Meschede's first over, but the 21-year-old got his revenge when the Surrey wicket-keeper looked to cut the final ball and was caught at gully by Nick Compton for 11. Meschede struck again in his next over, when De Bruyn was caught by Kieswetter for 10.
Gareth Batty and Zafar Ansari saw Surrey onto 153 when Ansari looked to drive Meschede and was caught by Kieswetter for 14. The seventh-wicket partnership added 37 runs in 12 overs.
The introduction of Chawla into the attack from the River End was greeted with a six by Batty over long on, a stroke he repeated two overs later. Batty moved onto 37 when he pushed forward to Meschede and was caught at first clip by Hildreth. Stuart Meaker and Tremlett took the total onto 197, before Chawla wrapped up the tail.
Meaker pushed forward and was caught by Marcus Trescothick at slip for 20 and, three balls later, new batsman Jade Dernbach was well caught at deep square leg by Thomas running to his right.
Chasing 133 for victory, Somerset lost Chris Jones, who was bowled by Dernbach shouldering arms with the total on 15. Trescothick showed his intention when he played two expansive cover drives off Tremlett. But on 25 he was caught at cover by Rory Burns looking to drive Dernbach.
Compton was joined by Hildreth and it was Compton who brought up the Somerset fifty with a single off Meaker. The third-wicket pair added 34 runs when Compton played Meaker to deep backward point, where Ansari fielded and threw to the keeper who ran Compton out while he went for a second run.
Hildreth was joined by Kieswetter who brought up the hundred with a single to cover off Ansari before dispatching Dernbach over the mid-wicket boundary as Somerset closed in on victory. Kieswetter repeated the exercise off Dernbach's next over, followed shortly after with a four.
The fourth-wicket pair remained together to see Somerset to 133 off 23.4 overs, by which time Hildreth had moved onto 36 and Kieswetter 34.