An unbroken 47-run 10th-wicket partnership between Deon Kotze and Louis Klazinga gave Namibia a thrilling victory in Windhoek on Sunday just when it looked like Scotland would take all 20 points on offer.

For most of the day Ryan Watson and his men were clear favourites to wrap up the win having set Namibia a formidable fourth-innings target of 237 for victory. And although Namibia’s batsmen tried hard throughout the third day, they never looked like pulling off a victory.

That is until Klazinga joined Kotze in the middle. With almost 50 runs to win, no one at the pleasant Wanderers Cricket Ground would have given them much of a chance. But the pair grafted away, knowing that time was on their side and they picked off the runs as the Scotland bowlers became more and more frustrated, striving as they did to capture that elusive 10th wicket.

In the end, Kotze made 35 not out and Klazinga 18 not out as the home side sneaked home by just one wicket. Number nine Kotze faced 107 balls in a knock that included just two boundaries while a watchful Klazinga faced 73 deliveries in what proved to be perhaps the most crucial innings of his career to date.

Earlier Sarel Burger made an important 78 off 162 deliveries to set up the thrilling finish for the tail-enders with Nicolaas Scholtz also getting in on the act with 30.

Scotland’s bowlers fought hard during the day with John Blain finishing the match with impressive figures of 37-9-106-9, having taken another four wickets in the second innings. He was well supported by Glenn Rogers (2-48).

But the Scots will know that really, having reduced Namibia to 105-6 and later 170-8 and 190-9, they should really have sewn the match up before Kotze and Klazinga got into their stride and past the winning post at 237.

It keeps Namibia’s unbeaten record in this year’s ICC Intercontinental Cup going. The south-west Africans have extended their lead at the top of the table to 18 points although Kenya, in second place, has one game in hand.

And with wins like this under its belt who would bet against it making its first ICC Intercontinental Cup final? Certainly, the players will be thinking it could be their year.

Namibia now has 82 points with Kenya on 66. In third position on 49 points, Ireland is still very much in contention as it has a game in hand over Kenya and two over Namibia.

For Scotland this defeat means heartbreak and unless it witnesses a significant turnaround in fortune it is very unlikely Watson and his men will qualify for the final in November. Luck has deserted the Scots in this tournament with some early games being washed out, seriously hampering progress on the points table, and now this.