Updated

Evan Longoria hit a solo homer and drove in four runs to help the Tampa Bay Rays beat the Texas Rangers 8-6 on Wednesday, completing a sweep of the three-game series between potential playoff opponents.

Longoria also had a pair of RBI doubles and a sacrifice fly. The All-Star third baseman had three RBIs in Tampa Bay's 10-1 victory Tuesday night.

James Shields (11-11) allowed two runs and four hits over seven innings, stopping a personal two-game slide. He had given up 12 runs over nine innings in his previous two outings.

Tampa Bay, which began the day tied with the New York Yankees for the AL East lead, has won five straight overall.

Taylor Teagarden and Mitch Moreland homered for the AL West-leading Rangers, who are 7-10 since July 30. AL batting leader Josh Hamilton had a run-scoring grounder in the eighth but went 0 for 4 for the day and 1 for 10 in the series.

Moreland hit a two-run shot off Lance Cormier in the ninth but Rafael Soriano came in and got the final two outs for his 35th save.

Longoria hit an RBI double off Derek Holland (2-2) in the first and a solo drive in the fourth for his first homer in 20 games, making it 2-0.

Tampa Bay went up 5-1 in the fifth on B.J. Upton's 11th homer, Longoria's run-scoring double and a bases-loaded walk to pinch-hitter Matt Joyce.

Joyce also singled in a run in the seventh and Longoria added a sacrifice fly in the eighth.

Teagarden cut the Rangers' deficit to 2-1 with a fifth-inning homer. He has connected three times in his last five starts.

Holland, recalled from Triple-A Oklahoma City before the game, made his first big league start since May 30. The left-hander gave up five runs and six hits in 4 1-3 innings.

Andres Blanco helped the Rangers close to 5-2 in the sixth, taking advantage of a pair of miscues by Shields. Blanco reached on an infield single and went to third when Shields was charged with an error for an errant pickoff attempt. He scored on a wild pitch.

The victory was the 900th for the Rays, who started play in 1998.

NOTES: Shields has given up 29 homers this season. ... Rangers 3B Michael Young (stiff neck) was out of the lineup for the second straight game. ... Tampa Bay RHPs Jeff Niemann and Wade Davis, both sidelined with strained right shoulders, had bullpen sessions and will pitch simulated games Friday. ... Hamilton was the DH for the second consective game. "I want to get him off the (artificial) turf," manager Ron Washington said. ... Rangers SS Elvis Andrus had a scheduled day off. ... Tampa Bay will wear team plaid jackets called "Braysers" as the theme for a West Coast trip that begins Thursday at Oakland. ... The Rangers optioned reliever Pedro Strop to Oklahoma City.