PITTSBURGH -- The vagaries of baseball never cease to amaze, and all of its unpredictable quirks were on display Sunday night to entertain a national TV audience and stun the Pittsburgh demographic.
Seemingly poised to complete a game-long comeback in the face of a four-run first-inning deficit to the Cardinals, the Pirates were staging a ninth-inning rumble against St. Louis closer Trevor Rosenthal.
The Bucs had sliced the Cards' lead to 6-5. They had the bases loaded, none out. They had two of their hottest hitters coming up. They had 32,065 in PNC Park going nuts.
The score never changed, the Cardinals slinking out of town with a victory that salvaged for them the finale of a series they had already lost.
"We got [Ike] Davis and [Jordy] Mercer, and they've been swinging the bat from a really good place," Pirates manager Clint Hurdle said. "We just weren't able to cash in."
Davis hit a foul pop to the second baseman. Mercer, with already a homer and double in the game, hit a slow comebacker that Rosenthal turned into a game-ending 1-2-3 double play.
The finish was pulsating enough to make the Cardinals feel like they got away with an impossible feat: A walk-off on the road.
"That felt like a walk-off win for us right there," St. Louis manager Mike Matheny said. "It's an understatement that we needed to pull one out there, especially after getting good offense like we did in the first."
"Really, hit anywhere but there, and we're still playing," said Mercer, alluding to how slowly the ball had been hit to the left of the mound. "But we've got to move on, get ready to play the next one."
The Pirates are moving on in a jig, following a 6-3 homestand Hurdle called "Nine games of hard."
"We had to play a lot of games uphill," Hurdle added. "It was a good, positive homestand. We fought to the end."
For the seventh time in the nine games of the homestand, the visitors scored first. And the Cardinals scored four in an ugly first that the Bucs spent the rest of the night putting makeup on.
That four-run first was set up by Pedro Alvarez's throwing error on a rather simple grounder to third. Jhonny Peralta was on first after being hit by a pitch when Matt Holliday sent the bouncer to Alvarez, whose throw for a force at second -- and a likely inning-ending double play -- drifted away from Neil Walker into right field.
The miscue resulted in runners at the corners, and the Cards were set up. Allen Craig's single cashed in Peralta, and RBI singles by Yadier Molina and Mark Ellis wrapped around Matt Adams' sacrifice fly gave Shelby Miller a 4-0 lead before he'd made a pitch.
Three of those runs were unearned, which, for Morton, was business as usual. They raised his season toll to nine unearned runs, already matching his burden for all of last season.
"Yeah, but I gave up a lot of hits there," Morton said. "That can't happen. Maybe a run scores [due to the error] ... but I can't let them score four there."
From there, Morton posted four zeros, encouraged by the comeback tendencies the Bucs had shown all month.
"Keep the Cardinals to four runs, keep the team in the game," said Morton, summing up his secondary goal. "I can't turn back time, can't take those four off the board. I started throwing the ball better, and we began chipping away, just didn't get there."
Alvarez almost got even in the third, after the Pirates loaded the bases on Tony Sanchez's leadoff single and two-out walks to Walker and Andrew McCutchen. However, Alvarez's drive on Miller's first pitch to straightaway center was caught on the warning track by Jon Jay.
Mercer's first homer of the season, following a walk of Davis, stirred the Bucs to offensive life in the fourth.
They struck again in the seventh, after Miller had already given way to his relief. Gaby Sanchez delivered a pinch-single off lefty Kevin Siegrist and McCutchen walked with two away, then Alvarez cashed in the opportunity with a solid single to center, making it 4-3.
The Cardinals, having gone from a 3-0 lead to a 4-3 defeat only the night before, struck back for two runs in the eighth against reliever Bryan Morris on Peter Bourjos' RBI single and a scoring wild pitch.
The Bucs again tried to ambush Carlos Martinez, who had surrendered Walker's game-winning three-run homer in the series opener. Davis began the eighth with a single and Mercer followed with a double into the left-field corner. However, Tony Sanchez's scoring grounder was all the Pirates could net out of that threat.
They went after Rosenthal with a vengeance in the aborted ninth: Walker double, McCutchen RBI single, Alvarez single, a four-pitch walk of pinch-hitter Clint Barmes to load the bases.
Then it was over, as was Miller's bizarre track record against the Pirates. He was able to turn the big early lead into his own victory after having started this game with a 1-5 lifetime record against the Bucs and 19-6 against everyone else.
Tom Singer is a reporter for MLB.com and writes an MLBlog Change for a Nickel. He can also be found on Twitter @Tom_Singer. This story was not subject to the approval of Major League Baseball or its clubs.