SAN FRANCISCO -- If injured slugger Manny Ramirez is sidelined for a prolonged period, the Los Angeles Dodgers have plenty of others who can produce.
James Loney hit a go-ahead, two-run single in the fifth inning to give Los Angeles a boost after Ramirez injured his right hamstring, and the Dodgers beat the San Francisco Giants 4-2 on Tuesday night.
"We've struggled here for the last two or three weeks," manager Joe Torre said. "It's nice to win two."
Matt Cain (6-7) lost his third consecutive start and fell to 0-8 in 14 career starts against the Dodgers, who have won four of five against San Francisco this season.
Ramirez hurt his hamstring running the bases and left the game. The Dodgers were going to wait until they checked him out Wednesday morning before speculating about how much time he might miss. No MRI was scheduled yet, but Ramirez won't play Wednesday.
"I'm not thinking about the DL right now, I'm thinking about how he comes in tomorrow," athletic trainer Stan Conte said. "I'll know a whole lot more tomorrow in terms of how he recovers."
Ramirez rounded second on Loney's two-out single and held up slightly before dashing back to the bag as the Giants threw behind him. Ramirez extended his right foot and made contact with shortstop Edgar Renteria's glove. The ball came out and Ramirez was safe.
Ramirez was clearly hurt because he immediately made his way toward the dugout and was met by Conte and Torre.
Ramirez had singled to get aboard after getting three hits with an RBI double Monday in a 4-2 victory.
Kemp, out of the starting lineup for a third consecutive day because of his recent struggles, replaced Ramirez on the bases and then took over in center field, with Reed Johnson sliding over to Ramirez's spot in left.
Kemp singled in the seventh and ninth but is still batting only .208 (20 for 96) in 26 games in June.
"I'm just trying to get that feeling back," he said. "Hopefully this is a start."
Torre thinks it can only help.
"A couple hits is not going to hurt his confidence," Torre said.
Ely ended a six-start winless stretch in which he was 0-4. He pitched seven solid innings to earn his first victory since May 22 against Detroit -- taking some serious pressure off the Dodgers' taxed bullpen. He allowed five hits and one run, struck out five and walked three.
Justin Miller allowed a home run to Pat Burrell to start the ninth but recovered to get two outs. Ronald Belisario recorded the final out on one pitch for his first career save. Both closer Jonathan Broxton and reliever Hong-Chih Kuo were unavailable because of their workload in recent days.
Russell Martin returned to the Los Angeles lineup after a day off and had two hits, scored a run and stole two bases.
Cain followed his season-low 2 2/3 innings at Houston on Thursday by getting knocked out after five already with 105 pitches. He allowed four runs and seven hits, struck out six and walked three.
When asked about his record against the Dodgers, Cain didn't utter a single word. Silence.
"We have confidence, but in the back of his mind he knows he's never beaten us," Torre said. "The human element can grab you."
The Giants, who hit into five double plays Monday night, have lost four consecutive series. It doesn't get any easier before the All-Star break, either. After the series finale Wednesday afternoon, San Francisco -- in a stretch with 20 in a row before the break -- heads to Colorado for four games, Milwaukee for four and then three at Washington to wrap up the first half.
Giants slugger Pablo Sandoval made his second baserunning blunder in as many games. He rounded second on Burrell's single, then flopped to the ground while trying to get back to the bag but came up well short. That came after he was caught in a rundown between first and second Monday night on Renteria's shallow fly, so it wound up being a double play.
"It's a couple times," manager Bruce Bochy said. "He's really a good baserunner, just a little overaggressive."
- Giants OF-INF Mark DeRosa will undergo season-ending wrist surgery Thursday in Cleveland, performed by Dr. Thomas Graham. DeRosa has been out since May 9 with an inflamed nerve in the wrist.
- Injured Giants RHP Todd Wellemeyer, on the disabled list since June 11 with a strained right quadriceps, will travel to Arizona on Wednesday for a week of rehab work. He has thrown two bullpen sessions but will begin fielding drills and increase from jogging to running.
- Kemp and Torre met before the game to discuss the center fielder's benching. Torre said Kemp would start Wednesday, when RF Andre Ethier was set to rest.