It was the advantage Biaggi needed to stay ahead at the chequered flag, the reigning champion completing his second podium appearance of the day to notch up a total of 40 points.
Despite losing out to Biaggi, Melandri's can still be satisfied with a mightily impressive WSBK debut, one that suggests he will be amongst those to make a successful transition from MotoGP to Superbike racing.
Further back, Jonathan Rea bounced back from his race one disappointment to take a deserved fourth position, the Castrol Honda rider catching and passing Haslam on the final lap.
Having run at the front of the field early on, it was a frustrating race for BMW, with Haslam fading to fifth eventually, while Corser ruined his chances of a good result by running off the circuit whilst disputing second.
The same can be said for Eugene Laverty, who was up with Melandri in fifth place when he ran wide at MG and was forced to take a trip across the grass. He would recover to 15th to claim a single point.
An astonishing ride by Leon Camier would see him defy illness to finish in sixth position, the Aprilia rider even making up two places on the final lap at the expense of Michel Fabrizio and Noriyuki Haga.
Tom Sykes completed a second top ten finish of the day in ninth, but his Kawasaki team-mate Joan Lascorz comes away with a double DNF following a technical issue.
Having finished outside the points in race one, Ruben Xaus sneaked into the top ten aboard the second Castrol Honda, ahead of Jakub Smrz, Roberto Rolfo and Josh Waters, while James Toseland slipped to an eventual 14th having run as high as tenth initially.