TORONTO (AP) -- Baltimore catcher Ramon Hernandez knows his team can't afford to watch four-run leads turn into one-run losses.
Alex Rios scored when Freddie Bynum misplayed a grounder at shortstop in the bottom of the ninth and the Toronto Blue Jays scored five times in the final three innings to beat the Orioles 7-6 on Tuesday night.
"These are the kind of games you can't lose," Hernandez said. "It's really hard to lose a game when you're winning going into the seventh by four or five runs."
It was Toronto's first walk-off victory since a 2-1 win over the New York Yankees last Sept. 13.
"We needed a game like that, a come-from-behind game, as far as getting the club rolling," Blue Jays manager Cito Gaston said. "Hopefully it will give us a boost."
"It was a breaking ball down," Hernandez said. "I tried to throw as quick as I could. Rios runs pretty good. I ended up trying to be too quick and throwing it away."
Orioles manager Dave Trembley said there was no excuse for his team's late-game gaffes.
"It doesn't take a rocket scientist to figure it out," Trembley said. "If you're going to give them five outs late in the ball game, they're going to score a run and they're going to be beat you."
A testy Bynum was in no mood to discuss the play afterward.
"If you watched the game you know what happened, so what do you want to talk about?" he snapped.
Blue Jays starter Dustin McGowan left after four innings with a sore right shoulder and will have an MRI Wednesday. He allowed four runs, though only two were earned, on four hits.
"It's been tender, but tonight it really started barking on me," McGowan said. "It just went a little overboard."
B.J. Ryan (2-3) worked a perfect ninth after the Blue Jays came back from a 6-2 deficit.
"This is a huge one," Toronto's Vernon Wells said. "We need a bunch more like this in order to get back in this thing."
Orioles right-hander Daniel Cabrera left in the seventh after two of the first three batters reached safely. Dennis Sarfate came on and got Joe Inglett to fly out, but loaded the bases with a walk before Alex Rios hit a three-run triple and Wells followed with a game-tying single.
"They showed a lot of patience," Trembley said. "Sarfate was getting behind, they fouled off some pitches. They made him come across the plate, they didn't chase pitches out of the strike zone."
Cabrera allowed four runs, six hits and four walks in 6 1/3 innings.
"He worked way too hard tonight," Trembley said. "He just didn't seem to get in any kind of rhythm early."
Aubrey Huff's solo shot in the first was his 18th of the year, but Toronto tied it in the bottom half on Wells' RBI single.
Baltimore scored two unearned runs in the third when Rolen couldn't come up with Adam Jones' leadoff grounder to third. Jones took third on Fahey's sacrifice and scored on a wild pitch before Brian Roberts walked, stole second, went to third on an infield single by Nick Markakis and scored on Huff's sacrifice fly.
Baltimore made it 4-1 in the fourth on Jones' double, but Toronto got one back in the bottom of the inning when Rod Barajas hit an RBI single.
Markakis made it 6-2 in the seventh with a two-run single off left-hander Scott Downs.
Rolen's error was just his fourth of the season. ... Baltimore placed LHP Adam Loewen (left elbow) on the 15-day DL and purchased the contract of LHP Alberto Castillo from Triple-A Norfolk. Loewen will consult with doctors before deciding whether to undergo surgery for the second time in the past two years. ... Toronto Maple Leafs coach Ron Wilson attended the game.
Washington Nationals re-signing Ryan Zimmerman to one-year, $1M deal, source says
After opting out of the 2020 season amid the coronavirus pandemic, Ryan Zimmerman is re-signing with the Nationals on a one-year, $1 million contract, a source confirmed to ESPN.
Tributes to a legend: Baseball world and beyond honors Hank Aaron
Athletes, civil rights leaders and other luminaries shared on social media what the Hall of Famer and American icon meant to them.
Howard Bryant shares lasting memories of Hank Aaron
Howard Bryant reflects on the moments he shared with Hank Aaron while writing a biography of the Hall of Famer.
Tim Kurkjian reflects on the respect given to Hank Aaron
Tim Kurkjian reflects on Hank Aaron's legacy and how he was revered by everyone in MLB.
Anthony Bass agrees to Marlins deal, could be big fish as closer
Well-traveled right-hander Anthony Bass agreed to terms Friday on a deal with the Marlins and is expected to compete for a role as their closer.
Stephen A. expresses his gratitude for Hank Aaron
Stephen A. Smith is thankful for Hank Aaron's impact on and off the baseball field.