Melansons strike, coming after some superb work from fellow sub Shaun Jeffers grabbed an unlikely win for a Yeovil side that were hard working but out of touch in front of goal.
Yeovil included two new trialists in their starting lineup with ex Peterborough defender Kane Ferdinand and Luton midfielder Andrew Parry joining the rest of Paul Sturrock's preseason squad. The Glovers lined up with ex City keeper Chris Weale between the sticks while Steve Cotterill's team included former Glovers Luke Ayling, Luke Freeman and Korey Smith.
The first half was a very quiet affair with neither keeper really tested to any level. New City signing Jonathan Kodjia, signed from French side Angers for £2 million, looked lively up front and shot well wide with his first chance on two minutes.
Kodjia then set up Joe Bryan but the left wing back's right foot shot whistled a yard wide of the far post. A minute later and the only on target opportunity of the first half fell to Matt Dolan but his left foot shot lacked power and City glove man Frankie Fielding saved easily.
Yeovil also came close on 24 minutes when after Premier League official Kevin Friend played a good advantage, Mark Beck went on and shot, his effort deflected for a corner. The only other chance of note saw Marlon Pack drive well wide after Aaron Wilbraham had laid the ball back to him.
Six minutes into the second half, Wilbraham headed inches wide from a pinpoint Ayling cross. Then Marc Laird tested Fielding with a shot he did well to keep down from 25 yards before City then came closer still when Wilbraham's flicked header came off the front of the crossbar. Kodjia then had another attempt in the 70th minute but a covering defenders block took the sting out of the shot.
With a quarter hour remaining, Mark Little's run from right back was found by Freeman but Weale got down quickly to save to his left. Weale then could only watch as an audacious piece of skill from Kodjia set himself up for a shot that rolled just wide of the post. Smith then tried his luck from twenty yards but his shot was deflected and gathered by Weale.
What looked to be the last chance of the game fell to Bird who sliced his shot wide from 25 yards out, summing up both sides inability in front of goal. But then came the late, late twist. Shaun Jeffers produced a brilliant run down the right flank and crossed for Melanson to slide in at the back post to grab a dramatic late winner.
Yeovil: Weale, Ferdinand, Smith, Parry, Lacey, Arthurworrey, Laird, Dolan, Beck, Burrows, Dickson
Subs: Jeffers for Beck 58 min, Bird for Burrows 58 min, Melanson for Dickson 80 min, Sowunmi for Arthurworrey 80 min