ST. PETERSBURG, Fla. -- Andy Pettitte wriggled out of several early jams and finished with a typical result against Tampa Bay.
Pettitte allowed three runs over seven innings and Hideki Matsui homered to lead the New York Yankees past the Rays 5-3 Tuesday night for a two-game sweep.
"All of my pitches were working for the first time," Pettitte said. "I'm definitely pleased with where it's going. Each game has gotten better and better. I'm just real happy that I was able to get to my curveball a lot tonight. My curveball has been non-existent."
Pettitte (2-1) gave up nine hits -- seven in the first three innings -- struck out five and walked three. The left-hander is 14-3 against Tampa Bay overall, including 8-1 in games at Tropicana Field. Pettitte got the loss in his first start of the season against the Rays on April 5.
"I felt like I was throwing batting practice through the first three innings," Pettitte said. "They were just so aggressive and obviously getting hits. I was fortunate to get out of the first couple innings without letting them do too much damage."
Mariano Rivera pitched the ninth for his fifth save in five opportunities.
The Yankees open a two-game home series with Boston Wednesday.
"I think it was important that we won these two games," Yankees manager Joe Girardi said. "We go home with a 4-4 road trip that didn't start off too well. We lost the first two, won a couple, then lost two more. Hopefully it carries over."
Bobby Abreu walked, went to third on Alex Rodriguez's 400th career double and scored on Matsui's run-scoring grounder to tie it at 2 in the fourth. A-Rod then scored on Edwin Jackson's wild pitch to make it 3-2.
Derek Jeter and Abreu extended the Yankees' advantage to 5-2 with run-scoring singles in the fifth. Jeter's hit came on a nine-pitch at-bat, while Abreu had been hitless in his previous 12 at-bats against Jackson.
Jackson (2-1) gave up five runs and four hits in five innings. He struck out four and walked four.
"It's just one of those games where you battle and try to keep the team in it by keeping the game as close as possible," Jackson said.
Jason Bartlett hit an RBI infield single in the sixth to get Tampa Bay to 5-3.
Matsui put the Yankees ahead 1-0 with a homer in the second, his third of the year. But Jonny Gomes and Mike DiFelice hit two-out, run-scoring singles to give the Rays a 2-1 lead in the third.
The Yankees failed to score after loading the bases with one out in the seventh. Abreu flew out and Rodriguez struck out against J.P. Howell. Rodriguez is 1-for-14 with runners in scoring position this season.
New York also left the bases filled in the eighth when Johnny Damon flew out with two outs.
Tampa Bay loaded the bases with one out in the bottom of the second, but Pettitte worked out of the jam by inducing a double-play grounder from Bartlett.
"We gave ourselves a lot of chances and we couldn't finish it off," Rays first baseman Carlos Pena said. "We couldn't get to Pettitte."
Girardi said C Jorge Posada (right shoulder) is getting close to playing defense. Posada can DH. ...Former Yankees general partner Steve Swindal attended the game. ... Yankees RHP LaTroy Hawkins might switch from No. 21 to 22 Wednesday. Some fans have objected to the pitcher wearing the number used by former OF Paul O'Neill. Hawkins declined to discuss the matter after the game. ... Pettitte has won seven straight decisions at Tropicana Field. ... The entire Rays team wore No. 42 in honor of Jackie Robinson Day. Robinson made his major league debut 61 years ago Tuesday. Girardi, 2B Robinson Cano, SS Derek Jeter and closer Mariano Rivera, whose regular number is 42, also wore No. 42. "Sixty-one years later, the impact is still felt on a daily basis," Girardi said. ... Rays RHP Matt Garza (right arm nerve irritation) threw off a bullpen mound. He could return before the end of the month. ... The Rays and Triple-A Durham have agreed to a two-year player development contract extension through 2010.