Ireland lost two wickets to the final two balls to go down by one run in their final warm-up game ahead of the T20 World Cup qualifying tournament.
In reply to Scotland's imposing 210-8, Ireland were 201-7 after 19 overs and when Mark Adair hit the fourth ball of the final over to the boundary they were within three runs of completing a superb chase.
But, next ball, Adair was bowled by Safyaan Sharif and David Delany's attempt to hit the winning runs resulted only in a leg bye, with the batsman run out attempting an impossible second to tie the scores.
But without Paul Stirling and Boyd Rankin in the line-up, this was another impressive Ireland showing and augurs well.
They lost Kevin O'Brien first ball but Andrew Balbirnie hit 70 from 48 balls (six fours and three sixes) and Gareth Delany and Harry Tector both scored at a strike rate of over 200 as Ireland reached halfway at 110-3.
Gary Wilson was out in the next over for 22 off 14, but although Simi Singh lasted only six balls, Adair and George Dockrell took 25 off the 17th over and looked as if they had done enough until Sharif's late, late intervention.
Scotland opener George Munsey had dominated the first quarter of the match, hitting 86 off 41 balls with nine fours and five sixes, before Delany, in his first match since the Tri-Series last month, had him caught at deep mid-wicket in his second over.
The young Clontarf paceman came back for the final two overs, took two more wickets and conceded just five runs from the last. But in the end the difference was a six. Both teams hit 25 boundaries, but Scotland had 11 sixes, one more than Ireland.