Barrowman (left) slides in to to give Inverness the lead
Goals from Andrew Barrowman and Roy McBain helped Inverness achieve their first ever win over Aberdeen.
The visitors took the lead after 27 minutes when Ross Tokely crossed for debutant Barrowman to fire home.
Inverness had a good chance to double their lead midway through the second half but Dougie Imrie's effort went high over the crossbar.
But it mattered little as McBain sealed the win in the last minute after being found by an excellent pass by Imrie.
Aberdeen were hoping to maintain their record of never having lost to Inverness in 17 matches.
And the hosts stated their intentions early on when Mark Kerr's first-minute cross was just out of the reach of striker Lee Miller.
Inverness struggled to put pressure on the Dons defence with Barrowman rather isolated as the lone frontman.
But the Highlanders were almost handed the opening goal when Aberdeen goalkeeper Jamie Langfield's slack clearance landed at the feet of McBain but the midfielder's shot was blocked by Aberdeen captain Scott Severin.
The hosts almost took the lead in the 20th minute when Jamie Smith's corner found Severin, whose left-foot shot was cleared off the line by McBain.
Jeffrey De Visscher then found himself in space on the edge of the Inverness penalty area and shot towards Michael Fraser's right-hand post but the goalkeeper parried wide.
The breakthrough came after 27 minutes when Imrie released Tokely on the right and his cross was dispatched into the net by debutant Barrowman.
Aberdeen attempted to hit back straight away but Charlie Mulgrew's free-kick was blocked by Imrie as Inverness held firm until the interval.
Smith and Imrie battle for possession at Pittodrie
Darren Mackie was introduced at the start of the second half with De Visscher withdrawn for the home side.
The striker almost made an instant impact on 49 mintues when he got into a shooting position near the penalty spot but his shot went wide.
Aberdeen were finding it difficult to carve out chances in front of the Inverness goal and Jamie Smith further frustrated the home fans by firing his 59th-minute shot over.
Inverness missed an excellent opportunity to clinch the win after 66 minutes when another loose clearance by Langfield found its way to Imrie, but the midfielder's shot sailed over the bar.
With ten minutes remaining, Mackie capitalised on a mistake by Phil McGuire to send over a dangerous cross but Inverness captain Grant Munro made a vital clearance.
Munro was then called upon to halt Mackie's progress as the substitute tried to muscle his way towards goal.
As Aberdeen pressed for an equaliser, Inverness capitalised with a goal on the counter attack in the 90th minute.
McBain, who was making his 300th appearance for the club, was found by Imrie's intelligent pass and the midfielder finished well past Langfield.
As the match entered injury time, Aberdeen almost scored a consolation goal with Smith's shot hitting the post.
Aberdeen: Langfield, Foster, Severin, Considine, Mulgrew, De Visscher (Mackie 45), McDonald, Kerr (Diamond 74), Jamie Smith, Miller, Maguire (Young 64).
Subs Not Used: Bossu, Duff, Mair, Stuart Smith.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.