ST. PETERSBURG, Fla. -- For the second day in a row, Jerry Sands came through in a pinch.

Sands' pinch-hit two-run homer off of Brian Matusz in the bottom of the eighth inning helped lift the Tampa Bay Rays to a 5-4 victory over the Baltimore Orioles on Monday night.

On Sunday it was Sands' pinch-hit RBI single that gave the Rays a 4-3 victory over the Houston Astros.

"I'm not sure if I'd say I'm a good pinch hitter," Sands said. "I don't know the stats, but I wouldn't say so. It was all pretty new to me when I did it with the Dodgers briefly. But I've picked up some things and I would like to say I've gotten a little better at it. The main thing is just trying to stay mentally prepared."

It was Sands' first home run since Sept. 20, 2011, when he was with the Los Angeles Dodgers.

"Whenever you get behind the count against the professional hitter it's not a good thing," Matusz said. "I followed it with a fastball down the middle and he made a good swing on it. I needed to make a pitch and I didn't, and we lost the ball game."

The Orioles had tied the game at 3-3 in the top of the eighth inning when designated hitter Nelson Cruz reached on an infield single with the bases loaded, scoring right fielder Nick Markakis with one out. Rays reliever Jake McGee recovered to strike out shortstop J.J. Hardy and retire pinch hitter Steve Pearce on a grounder to end the inning.

Orioles reliever Darren O'Day, who had walked third baseman Evan Longoria prior to Sands' homer, was credited with the loss. Sands' blast gave the Rays a 5-3 lead after eight.

"Both Brian and Darren and our other guys have gotten big outs in those situations this season," said Orioles manager Buck Showalter. "They made some good pitches but Tampa made some nice swings."

The Orioles pulled within one in the top of the ninth when pinch hitter Delmon Young hit a solo homer off of right-hander Juan Carlos Oviedo with one out. However, Oviedo recovered to retire Markakis and third baseman Manny Machado to record his first save of the season.

"We won a really tough game yesterday, we won a really tough game here tonight," said Rays manager Joe Maddon. "When you start believing you're going to win games late, that's a good feeling to get. That's when you start getting good again."

Rays starter Jake Odorizzi was cruising through the first five innings, yielding just one hit and enjoying a 3-0 lead when things turned sour quickly. He gave up a leadoff double to Markakis and a two-run homer to Adam Jones with one out in the sixth. That ended his night on the mound.

"He was able to hit that one pretty far," Odorizzi said. "I would assume it went pretty far. I didn't turn around to look at it because I knew it was gone. It was an unfortunate result to close the day."

Orioles starter Wei-Yin Chen gave up three runs and six hits over 6 2/3 innings in the no decision.

The Rays got on the scoreboard early when shortstop Yunel Escobar hit a home run well over the 370-foot sign in left-center in the first inning.

The long ball served the Rays well again in the bottom of the fourth when catcher Ryan Hanigan hit a two-run blast down the left-field line that scored designated James Loney and extended the lead to 3-0.

Meanwhile, Odorizzi was having one of his best outings of the season. He found a little trouble in the top of the second after giving up an infield hit to Hardy and walking left fielder David Lough following an 11-pitch battle, but a strikeout of second baseman Ryan Flaherty ended the inning.

NOTES: Orioles C Matt Wieters will undergo Tommy John surgery on his right elbow and miss the remainder of the season. Wieters had been on the disabled list since May 11. ...Orioles RHP Miguel Gonzalez is expected to be activated from the 15-day disabled list and start Tuesday's game. He is 3-3 with a 3.55 ERA in nine career starts against the Rays. ...A patch of padding was replaced with fencing in left-center field at Tropicana Field so fans can watch the game from the field level view. Rays 3B Evan Longoria hit a first-inning double into the fenced area. ...Rays RHP Jeremy Hellickson is scheduled to make his third rehab start Tuesday for Triple-A Durham at Louisville.