Scotland 10 South Africa 14:Scotland face the prospect of being drawn in the most exacting of World Cup pools after South Africa fought back to defeat Frank Hadden's side in the second Bank of Scotland Corporate Autumn Test at Murrayfield.
Scotland led 10-0 at half-time in an absorbing clash with the world champions and harboured genuine hopes of repeating their 21-6 triumph against the Springboks in 2002.
Victory would have catapulted the home side into the top eight of the world rankings at Ireland's expense and retained for them second-seed status for the 2011 World Cup draw.
But a try for replacement Jaque Fourie and nine points from the boot of Ruan Pienaar cancelled out Nathan Hines' first-half try for Scotland as the Springboks added to their rather more easily-achieved successes in Edinburgh in a World Cup warm-up last August and in November 2004.
This second defeat of the autumn series means Scotland, left to rue a succession of missed penalty kicks from Phil Godman and Dan Parks, could now feasibly be grouped with two powerhouses such as New Zealand and France when the draw is made for the tournament in two years' time.
Hadden felt his side missed a golden opportunity to beat the world champions.
"That was even more frustrating than last week," said Hadden, referring to the 32-6 defeat to New Zealand. "Our discipline let us down just after half-time and our concentration let us down in the last 10 minutes.
"We will never have a better chance to beat the world champions than today. Everyone is absolutely gutted. They knew the game was there for the taking.
"If we had kept our concentration and made good decisions in the last 10 minutes it would have been a different story.
"At the moment we can't see any positives because we thought we did enough to beat them."
South Africa head coach Peter De Villiers admitted his side had been given a tough test by the hosts.
"We showed some character. You can easily slip up on this one but we stuck to our guns," he told BBC1. "They came at us as and they have the ability to keep the ball in hand. They gave us a run for our money today but we are very happy at this moment.
"We now have a big one against England next week and we are looking forward to it."