CHICAGO -- The Pirates took advantage of Chicago Cubs miscues to end their seven-game losing streak Saturday.
The Cubs committed errors to put runners in scoring position and the Pirates happily drove them in, winning 7-6 at Wrigley Field.
The Pirates (73-71) had not win since Sept. 5, when they defeated the Houston Astros at home. They avoided dropping to .500 for the first time since June 2.
The Pirates used extra-base hits to build a lead and retained the lead with a strong outing from Wandy Rodriguez.
Clint Barmes and went 2 for 4 with a home run, and Andrew McCutchen homered as well. Starling Marte hit a double and a triple.
The Cubs committed two errors that led to four unearned runs off starter Jason Berken, who allowed six runs -- two earned -- in four innings. The Cubs claimed him off waivers from the Baltimore Orioles Sept. 7 to assume a rotation spot after they shut down Jeff Samardzija when he reached his innings limit.
The Pirates got six strong innings out of Rodriguez (11-13), who allowed three runs, one earned, and nine hits, all singles. He has allowed three or fewer runs in each of his past five starts.
Berken and the Cubs gift-wrapped the Pirates a run in the first. Berken hit Marte with two strikes. Welington Castillo threw down to first to try to pick off Marte, but the ball went into right field and Marte sped to third.
Berken walked Andrew McCutchen and Garrett Jones hit a sacrifice fly to score Marte.
A perfect hit and run contributed to a Pirates run in the second. Pedro Alvarez singled and broke for second on the pitch to Clint Barmes. Barmes grounded between first and second but Darwin Barney, who broke to cover the bag, couldn't get it, giving the Pirates men on first and third with no outs.
Rod Barajas smoked a single off the wall in left field to score Alvarez and put the Pirates ahead, 2-0.
Andrew McCutchen added to the lead in the third with his second home run in as many games. He smoked a full-count changeup off the safety fence at the top of the bleachers in left for his 28th of the season.
Another Cubs error put another Pirates runner in scoring position in the fourth, when Josh Vitters bounced a routine throw into the stands on a Barmes grounder. Three batters later, Marte tripled to the wall in right-center, starting a two-out, three-run rally that gave the Pirates a 6-1 lead.
Rodriguez's throwing error led to two runs in the fifth. After Dave Sappelt singled, Rodriguez threw the ball into center field trying to start a double play. A grounder from Joe Mather and a single from Alfonso Soriano scored runs and reduced the Pirates' lead to 6-3.
Bill Brink: firstname.lastname@example.org and on Twitter @BrinkPG.