SAN FRANCISCO — Tim Lincecum won for the first time in nearly two months to end the worst drought of his career and the San Francisco Giants held the Los Angeles Dodgers scoreless for the third straight game in a 3-0 victory Wednesday.

SAN FRANCISCO — Tim Lincecum won for the first time in nearly two months to end the worst drought of his career and the San Francisco Giants held the Los Angeles Dodgers scoreless for the third straight game in a 3-0 victory Wednesday.

Angel Pagan hit an RBI single and drew a bases-loaded walk to back Lincecum (3-8) as the Giants moved into a first-place tie in the NL West with the Dodgers by completing their second sweep of the season.

It was the first time in franchise history that they shut out the rival Dodgers in a three-game series, a stretch that spans 123 seasons.

Lincecum threw four-hit ball over seven innings for his first win since April 28. He struck out eight and walked two while outpitching Chad Billingsley (4-7). The two-time Cy Young Award winner ended a career-long 10-start winless stretch in which he went a career-worst 0-6.

He was 0-4 in his previous six starts against Los Angeles since his last victory on July 30, 2010.

Already missing injured All-Star Matt Kemp, the Dodgers lost Andre Ethier after one at-bat to a left oblique injury that could land him on the disabled list.

Pirates 11, Phillies 7

At Philadelphia, Chase Utley homered in his first at-bat of the season, but Pittsburgh spoiled his return by connecting three times to beat Philadelphia.

Michael McKenry hit a three-run homer and Andrew McCutchen and Casey McGehee also went deep for the Pirates in their highest-scoring game of the season.

Nationals 11, Rockies 5

At Denver, Jordan Zimmermann pitched seven strong innings, Ryan Zimmerman and Tyler Moore both homered for the second straight game and Washington beat Colorado.

Brewers 8, Reds 4

At Cincinnati, Rickie Weeks and Cody Ransom each hit a two-run homer off Homer Bailey, and Milwaukee avoided a three-game sweep by beating Cincinnati.

Zack Greinke (9-2) remained unbeaten against the Reds, allowing two runs in six innings. Greinke is 4-0 in six career starts against Cincinnati.

Mets 17, Cubs 1

At Chicago, Daniel Murphy homered twice, Scott Hairston hit a grand slam and David Wright drove in five runs as New York routed Chicago.

Ike Davis had a three-run homer and an RBI double as he combined with Murphy, Hairston and Wright to drive in all 17 runs — with each having at least four RBIs — to help the Mets snap a four-game losing streak.

Braves 6, Diamondbacks 4

At Atlanta, Chipper Jones and Jason Heyward homered, and Atlanta withstood Arizona's comeback attempt.

Jones' two-run shot off Trevor Cahill (6-6) in the sixth inning was his first homer since May 4.

Marlins 5, Cardinals 3

At Miami, John Buck and pinch-hitter Logan Morrison connected for consecutive home runs in the seventh inning, rallying Miami past St. Louis to end its eight-game losing streak against the Cardinals.

Astros 1, Padres 0

At Houston, Lucas Harrell pitched his first complete game and left fielder J.D. Martinez threw out a runner at the plate in the ninth inning to preserve Houston's victory over San Diego.

Athletics 2, Mariners 1

At Seattle, Jarrod Parker struck out a career-high nine in seven innings and Oakland's only two hits in a victory over Seattle were homers by Yoenis Cespedes and Coco Crisp.

Parker (4-3) allowed three hits and walked four. He has given up two earned runs in his last 20 innings, going 2-0 in those three outings and lowering his ERA to 2.57.

Yankees 5, Indians 4

At New York, Andy Pettitte broke his ankle on the same day the Yankees put CC Sabathia on the disabled list, but Robinson Cano hit a go-ahead homer to help New York beat the Cleveland Indians for a three-game sweep.

The AL East leaders face at least two starts without Sabathia and at least six weeks without Pettitte, the 40-year-old veteran who came out of retirement and had filled in admirably for a pitching staff hit hard by injuries — including the loss of starter Michael Pineda and closer Mariano Rivera.

Pettitte fractured his fibula near his left ankle in the fifth inning when he was hit by Casey Kotchman's line drive. Before the game, the Yankees announced Sabathia strained his groin against the Mets on Sunday night and still felt discomfort after throwing in the bullpen Tuesday.

Rangers 13, Tigers 9

At Arlington, Texas, David Murphy went 4 for 5 with two home runs and matched his career high with five RBIs for Texas and starter Roy Oswalt.

Ian Kinsler added a two-run homer and Adrian Beltre had three hits and an RBI in support of Oswalt, who earned his second victory in two starts with the Rangers, who had 16 hits.

White Sox 12, Twins 5

At Minneapolis, Chris Sale pitched seven easy innings and Adam Dunn hit a three-run homer to lead Chicago past Minnesota.

Sale (9-2) allowed two runs and six hits while striking out five and walking one. He was leading the league with a 2.27 ERA.

Angels 13, Orioles 1

At Baltimore, Torii Hunter homered and scored four runs, Jered Weaver pitched into the seventh inning and Los Angeles beat Baltimore for a two-game sweep.

Red Sox 10, Blue Jays 4

At Boston, David Ortiz hit his 399th homer and Boston scored six runs in the first inning against a wild Ricky Romero to beat Toronto for its fifth straight series win.

Adrian Gonzalez had three RBIs and Mike Aviles added two as the Red Sox improved to 9-2 in their last 11 games.

Royals 5, Rays 4

At Kansas City, Mo., Billy Butler greeted reliever Burke Badenhop with a solo home run in the eighth inning, powering Kansas City to a three-game sweep of Tampa Bay on a scorching afternoon.