Jackson kicks Scots to last-gasp win
Samoa had struck early through Kahn Fotuali'i's try, only for Nicky Walker to go over soon after.
The hosts had edged in front on several occasions, only to be pegged back by their visitors.
It looked as if the game was destined to end in a draw but ice-cool kicking from substitute Jackson edged the Scots to victory.
Scotland began the Test with purpose and within a minute had surged to within five yards of the Samoan line.
As the forwards tried to power over for a score, referee Steve Walsh spotted an infringement, giving Dan Parks a straightforward for a Scotland lead.
Samoa looked unsettled by the bitter cold at Pittodrie, with Tasesa Lavea and Fotuali'i opting to kick at almost every opportunity.
But nine minutes in they produced their first telling piece of backline play that resulted in a sweeping try.
Pisi had threatened only moments before down the left side, and after a slick move which went from Mapusua to George Pisi, the latter's grubber-kick was perfectly judged for Fotuali'i to scoop up the ball and touch down over the line.
Paul Williams had no trouble slotting the kick and turning the match the way of the visitors.
Scotland rallied again in a pulsating first quarter, running in their first try of the autumn with a sweeping move from Rory Lawson to Parks to Walker, who dashed in under the posts.
The home side dominated the scrum, and finished the half in the ascendancy, but had only another Parks penalty to show for their efforts.
Williams landed a penalty for Samoa before the interval to reduce the arrears to three points, and then levelled with another immediately after the break when miscommunication between Richie Gray and Richie Vernon from the kick-off invited a barrage of Samoan pressure.
The hosts responded when Graeme Morrison made a fabulous break which nearly led to a Scotland try. A penalty followed, but Parks missed a routine kick for the second time in the match.
Scotland continued to build well and after a 17-phase passage of play Parks landed a drop goal to restore the advantage.
But the visitors again hit back in what was a topsy-turvy encounter, and after a rare burst from David Lemi they won another penalty to level at 16-16.
Five substitutes from coach Andy Robinson signalled the home side's attacking intent as they continued to probe in search of a way over the line.
Samoa too were playing with adventure, enjoying their best spell of the game as the minutes ran down.
But with a couple of minutes remaining Jackson kicked deep to the far corner, and the forwards drew a penalty on the right from which Jackson scored the winning points.
The win extends Scotland's run to five in six, with the only defeat coming at the hands of in-form New Zealand.
Despite the score-line the result reflects well on a determined Scotland performance against testing opposition and brought their season to an end on a satisfactory note.