(CNN) -- Spaniard Pablo Martin retained his Alfred Dunhill Championship title by two shots on Sunday, despite nearly throwing away victory with a triple-bogey seven on the 17th hole at Leopard Creek, South Africa.
The 24-year-old led by five strokes with seven holes to play, but he stumbled on the home stretch and his lead had been whittled down to a single shot before a birdie on the final hole confirmed the win.
Martin carded a final round two-under-par 70 for a 72-hole total of 277 (-11) to become the first player since Padraig Harrington won back-to-back British Opens in 2007 and 2008 to retain a European Tour title.
South African rookie Anthony Michael, who led for the first three rounds, shared second place after fading with a final round 73.
Michael was joined on 279 by compatriot Charl Schwartzel (70) and Dane Thorbjorn Olesen -- who posted a best-of-the-day 66.
Martin told the official European Tour website: "I played really well on the front nine. I didn't get in too much trouble and I holed a couple of good putts.
"I've been playing decent lately and wanted to try my best and play as well as I could," added Martin, who claimed a first prize of nearly 160,000 euros and for the second year running becomes the first leader of this season's Race to Dubai.