SAN FRANCISCO — Marcell Ozuna hit a go-ahead single in the eighth after tying it with an RBI single in the sixth, and the Miami Marlins beat the San Francisco Giants 6-3 on Friday night for their ninth straight win at AT&T Park.

Center fielder Ozuna also threw out Andres Torres trying to stretch a sixth-inning double into a triple. Torres left the game and was having X-rays on his right knee after a hard slide on the play.

Logan Morrison hit his first home run in nearly a year and also had an RBI triple for the Marlins, who haven't lost in San Francisco since July 28, 2010.

A.J. Ramos (1-2) pitched a 1-2-3 seventh for his first major league win.

Pinch-hitter Greg Dobbs added an insurance run-scoring single in the eighth, when the Marlins rallied against Jake Dunning (0-1).

Morrison was activated from the 60-day disabled list June 9 after missing 11 months because of a knee injury that required surgery on Sept. 5.

He connected for his first home run since last July 6 leading off the second and tripled in the sixth. He now has a four-game hitting streak against the Giants.

Miami's Ricky Nolasco was tagged for nine hits — one below his season high — and three runs in 5 2-3 innings. The right-hander is still an impressive 4-0 with a 1.47 ERA in five career starts at AT&T Park, but nearly doubled his ERA in the waterfront ballpark. Steve Cishek, the Marlins' fourth reliever, allowed a pair of singles before finishing for his 12th save in 14 opportunities.

San Francisco starter Tim Lincecum retired 11 straight batters during one stretch but wound up with a no-decision in one of his better outings over the past month and also hit a stand-up triple in the sixth to end an 0-for-22 funk, sparking a roaring ovation from the sellout crowd of 41,490. It was the second triple of his career and first extra-base hit since a double on June 7, 2009, at Florida — also against Nolasco.

The triple chased Nolasco this time, but Gregor Blanco struck out against reliever Dan Jennings to strand Linceucm. The right-hander allowed three runs and four hits, struck out eight and walked one in seven solid innings as San Francisco lost for the fifth time in seven games.

Reigning NL MVP and batting champion Buster Posey went 0 for 5 while making his fifth start at first base to give him a break from catching. Hunter Pence and Marco Scutaro each hit RBI doubles for the Giants, who have a season-high seven-game home run drought.

NOTES: San Francisco 3B Pablo Sandoval (foot) homered in his rehab game with Class-A San Jose. ... Giants CF Angel Pagan, who aggravated his injured left hamstring and was carted off from his rehab outing with Class-A San Jose on Thursday night, received new MRI results but was waiting to see the doctor. ... San Francisco SS Brandon Crawford threw from up to 120 feet to test two sprained right fingers and should be back in the lineup Saturday. "It still doesn't feel good when I'm throwing," he said. "I don't have much behind it." ... Giants RHP reliever Santiago Casilla (right knee surgery) is set to throw a bullpen Saturday, likely face hitters early next week, then have two or three rehab outings before returning — perhaps by the end of the next road trip that ends July 4 at Cincinnati. ... Giants RHP Chad Gaudin wore a special sleeve over his pitching elbow Friday, a day after taking a line drive off the area. He plans to play catch Saturday and throw his bullpen on schedule Sunday with the hopes of making his next start. "I'm assuming, I'm planning on it," he said. "I'm optimistic."... Barry Zito (4-5) starts Saturday for the Giants just three days after the death of his father, Joe. The lefty is 5-1 with a 2.45 ERA in eight career starts against the Marlins. ... 49ers quarterback Colin Kaepernick threw out the ceremonial first pitch.