A goal by Paul Burns in the dying seconds was enough to give Queen of the South their first league victory of the season and lift them off the foot of the table.
The goal, however, came after a game Queens had virtually dominated and which saw Airdrie reduced to 10 men for the final half hour.
The Dumfries men had the better of the early stages, and only a super save by keeper Stephen Robertson prevented Willy Gibson making the breakthrough. The Queens striker had weaved his way past three men for a clear run-in on goal, but the keeper managed to turn the finishing shot round the post.
The blow for Airdrie came after 58 minutes when Allan McManus was red-carded as he seemed to elbow Brian McLaughlin off the ball as the Queens man weaved his way past him for a clear run in on goal.
Queens were unable to take advantage as they saw the Airdrie keeper again bring off a fine save as he dived to touch a 25-yard rocket from Eric Paton round the post.
Then came the dramatic last-minute goal as a Ukrainian trialist, who had been on for only eight minutes, slipped the ball through for Burns to snatch victory.
Queens boss Iain Scott was delighted at this first win in nine league games and said: "Perhaps this will lift the monkey off our back"
By contrast Airdrie boss Sandy Stewart said: "It was really disappointing to see that goal go in, but I have no quibble with the way the lads played."