ST. PETERSBURG, Fla. (AP) -- Ramon Hernandez had a breakout game and also helped a teammate overcome a second consecutive rough outing.
"When you're having a tough time, you hit the ball hard, you kind of know if it's going to leave or not," said Hernandez, who went 2-for-4 to increase his batting average from .156 to .194. "I was going to make sure it wasn't hooking foul."
Hernandez, who also had a run-scoring triple, gave Baltimore a 3-2 lead on his two-out homer off Dan Wheeler (0-1). The Orioles stopped a three-game losing streak.
"Ramon found a way to get the big hit," Orioles manager Dave Trembley said. "As soon as Hernandez hit the home run, as far as I'm concerned the game is over because Sherrill ain't going to let them score."
Carlos Pena homered for the second straight day off Orioles reliever Jamie Walker, a solo shot in the eighth that tied it at 2. Pena has three homers and seven RBIs in the first two games of the three-game series.
"I'm [mad] at myself," Walker said. "Last night I got beat on a bad pitch. I felt tonight I made a decent pitch, but decent pitches don't leave the yard. Obviously he's seeing something off of me. He's hitting like Babe Ruth the last two nights."
Walker gave up just two homers to left-handed batters in 81 appearances last season.
"We won the game, that's what matters," Walker said. "I'm Ramon's biggest fan right now. We've just got to keep plugging away."
Pena has six homers this season. He hit 46 last year, but only four came in April.
"Well, the guy's the natural," Trembley said. "That's what he's swinging it like."
Evan Longoria, taken third overall in the 2006 amateur draft by Tampa Bay, went 1-for-3 with a walk in his major league debut. The third baseman pulled the Rays within 2-1 on his first career hit, a groundball run-scoring single to left in the sixth.
"Nice first game for him," Rays manager Joe Maddon said. "Good at-bats. Well done."
Longoria admitted he was nervous during his first at-bat, which resulted in a grounder to second.
"It's probably the first in a long time," Longoria said.
Hernandez had an RBI triple in the second that put the Orioles ahead 2-0. It was his sixth career triple, coming on his 3,545th at-bat. Baltimore scored a run in the first when Nick Markakis hit into a double play.
It was the second time Hernandez has homered and tripled in the same game. The other came on Sept. 27, 2005 when he played with San Diego.
Markakis stayed in the game after getting hit by a pitch on the left wrist in the eighth. He had an ice pack on the wrist postgame, but he plans to play Sunday. ... Rays ace Scott Kazmir (left elbow) played catch one day after a 46-pitch batting practice session. He is scheduled to throw two innings in an extended spring training game Tuesday. ... Tampa Bay RHP Matt Garza (right arm nerve irritation) resumed playing catch. ... Rays RHP Jeff Niemann, taken fourth overall in the 2004 amateur draft, will make his major league debut Sunday. ... To make room for Niemann on the roster, the Rays optioned RHP Jae Kuk Ryu to Triple-A Durham. ... Orioles RHP Matt Albers will start Monday's game against Toronto. RHP Jim Johnson will replace Albers as the long man out of the bullpen.
McKenzie, Reyes and Indians beat Royals 4-0 for 4-game sweep
— Triston McKenzie bounced back from a rugged start to pitch one-hit ball into the sixth inning and the Cleveland Indians completed a four-game sweep by blanking the Kansas City Royals 4-0 Thursday.
Cordero snaps slump, Red Sox hold on to beat Tigers 12-9
— Franchy Cordero came off the bench with three hits to snap an 0-for-25 slump, then brought home the game-winning run in the eighth with the help of Detroit's fourth error, and the Boston Red Sox held on after blowing three previous leads to beat the...
Walker allows 1 hit in 7 innings, Mets walk past Cards 4-1
— Taijuan Walker allowed one hit in seven innings, the Mets scored three runs on bases-loaded walks and beat the St. Louis Cardinals 4-1 on Thursday.
Jose Altuve's birthday home run answers Bronx boos, lifts Houston Astros past New York Yankees
Jose Altuve responded to jeering fans by marking his 31st birthday with a go-ahead, three-run homer off Chad Green in the eighth inning, and the Astros beat the Yankees 7-4 Thursday to avoid a three-game sweep.
Mets' patience pays off vs. Cards
Jonathan Villar, James McCann and Pete Alonso display their patience as each draw walks to score runs in the Mets' win.
Atlanta Braves bring back C Tyler Flowers on minor league deal
Needing catching depth with Travis d'Arnaud and Alex Jackson on the injured list, the Braves have signed Tyler Flowers to a minor league deal.