Airdrie United had the chance to move off bottom spot snatched away when an injury-time goal from David Weatherston earned Queen of the South a point.
Against the run of play, Derek Holmes bundled Queens in front on 13 minutes.
Scott Gemmill fired home a low drive to level before the break and Ricky Waddle later nipped behind the home defence to hit the visitors in front.
It looked good for the Diamonds until Weatherston poked in a Joe Hamill free kick right at the death.
Airdrie looked the hungrier side from the start and Gemmill had a couple of efforts before Scott Fox pulled off a great one-handed save to stop a Scott McLaughlin volley.
The visitors continued to press, but Holmes hit his 12th goal of the season to give a tired Queens side the lead.
Craig Reid started the move down the right wing and Holmes was on hand to apply the finishing touch at the back post.
Three minutes before the interval, Airdrie hit back when McLaughlin's cross from the right found Gemmill, who had time to drill a low shot past Fox.
Kenny Black's side took a deserved lead five minutes into the second half when Gemmill turned provider and his through ball released Waddle to turn the ball past Fox with the help of a post.
Both sides then hit the woodwork, John Baird for Airdrie and Hamill for the Doonhamers.
Airdrie were left dejected when substitute Weatherston knocked the ball home from close range to leave them bottom of the league, one point behind Ayr United, with two games left to play.
An under strength Queens side without a few of their regulars were somewhat fortunate to share the points however the Doonhamers stuck to their task and were rewarded with that last gasp goal from Weatherston.
Queens MAD MAN OF THE MATCH - Craig Reid - An immaculate display from the most improved player of the season.