Mattias Ekstrom grabbed top spot in the first DTM free practice session of the weekend at the Norisring with his final lap of the session.
The Swede was set to end Friday's practice in second place after a couple of attempts in the final minutes had fallen short of the time set by his Abt Audi teammate Oliver Jarvis.
However, Ekstrom just managed to squeeze one more lap in as the checkered flag came out, and it was enough to jump the Briton by just 0.015sec.
Jarvis appeared to have first place all wrapped up after a frantic final 20 minutes of dry running in a session that had started off with a very wet track owing to heavy rain in the morning.
Audis had set the pace in the wet running, particularly the 2008-spec cars of Filipe Albuquerque and championship leader Martin Tomczyk.
Conditions improved throughout though, and there was a lull in the middle of the 90-minute session as the sun came out and teams waited for a full dry line to appear.
Mercedes sent all four of its frontrunning HWA cars out as soon as it deemed the track was fit for some dry running, but the C-class machines were soon overhauled once the Audis joined the fray a few minutes later.
Shortly before Ekstrom's best lap, the 2008-spec Mercedes of Maro Engel appeared set to knock Jarvis off the top of the pile. However, the German's lap fell away in the third sector, and he had to settle for the honor of top Mercedes.
Christian Vietoris was next up in another older C-class, while Bruno Spengler was the top HWA driver in fifth, ahead of Susie Stoddart, Gary Paffett and Tomczyk.
Three-time Norisring winner Jamie Green was only 12th, while last year's pole-sitter Ralf Schumacher brought up the rear of the field after he didn't complete many laps when the track was at its fastest.
Pos Driver Car Time Laps
1. Mattias Ekström Audi 48.867 41
2. Oliver Jarvis Audi 48.882 + 0.015 43
3. Maro Engel Mercedes 48.974 + 0.107 44
4. C.Vietoris Mercedes 49.001 + 0.134 44
5. Bruno Spengler Mercedes 49.019 + 0.152 47
6. Susie Stoddart Mercedes 49.067 + 0.200 47
7. Gary Paffett Mercedes 49.131 + 0.264 42
8. Martin Tomczyk Audi 49.162 + 0.295 50
9. R.van der Zande Mercedes 49.174 + 0.307 55
10. Timo Scheider Audi 49.189 + 0.322 39
11. M.Rockenfeller Audi 49.201 + 0.334 45
12. Jamie Green Mercedes 49.295 + 0.428 44
13. Miguel Molina Audi 49.389 + 0.522 54
14. David Coulthard Mercedes 49.397 + 0.530 43
15. Edoardo Mortara Audi 49.408 + 0.541 33
16. F.Albuquerque Audi 49.466 + 0.599 41
17. Rahel Frey Audi 50.428 + 1.561 43
18. Ralf Schumacher Mercedes 50.872 + 2.005 30