MIAMI (AP) - Ricky Nolasco allowed one run in eight innings and the Florida Marlins snapped a seven-game losing streak Friday night by beating the San Francisco Giants 2-1.
Florida improved to 4-0 this season against the defending World Series champions.
The erratic Marlins had been 0-7 on their homestand, but Nolasco (9-8) outpitched All-Star Matt Cain. Nolasco struck out four, walked one and gave up six hits.
Leo Nunez pitched around a leadoff single in the ninth to earn his 32nd save in 36 chances. Center fielder Dewayne Wise - a ninth-inning defensive replacement - made a lunging catch of Cody Ross' fly at the warning track for the second out.
The Giants set an NL record for consecutive solo home runs when Pablo Sandoval hit one in the first inning. Their past 20 homers have been solo shots, breaking the record of 19 set by the Philadelphia Phillies in 1914.
San Francisco subsequently hit into two double plays and lost another runner when Aubrey Huff was thrown out trying to steal.
Two of the first three Florida batters scored against Cain (9-9). He then settled down to pitch six innings, allowing no more runs, but lost his third start in a row.
There was no evidence of lingering ill will between the teams, who met for the first time since their series in May, when Giants catcher Buster Posey broke his leg in a collision with Florida's Scott Cousins. Cousins is on the disabled list himself with an injury unrelated to the collision, and before the game both managers said their teams wanted to move beyond the episode.
The Giants, starting a 10-game trip, lost for the 12th time in 17 games and continued to sputter on offense. They're next to last in the majors in runs and have totaled 15 in the past eight games.
Ross went 0 for 4 playing in Miami for the first time since the Giants acquired him from Florida on a waiver claim last August.
Sandoval gave San Francisco a brief lead when he hit his 14th homer with two out in the first.
Florida came back with two runs in the first on three consecutive one-out hits. Alfredo Amezaga singled, Logan Morrison tripled and Mike Stanton singled.
The Giants didn't advance a runner beyond first base in the final six innings.
Notes: Giants OF Carlos Beltran (strained right hand) missed his fourth consecutive game. Manager Bruce Bochy didn't rule out putting Beltran on the disabled list but said the Giants hope he'll heal quickly after he received a shot. ... Giants OF Nate Schierholtz, who had been sidelined with a right hip flexor, struck out pinch-hitting in the eighth. ... Marlins CF Mike Cameron (knee) was scratched from the starting lineup. ... Florida RHP Javier Vazquez returned from Puerto Rico, where his wife was ill, and he'll start Saturday. RHP Chris Volstad, recalled from Triple-A New Orleans, will make his first start since July 22 on Sunday. ... Giants RHP Tim Lincecum, scheduled to start Saturday, is 5-4 with a 1.67 ERA over his past 10 starts.