Updated

Michael McKenry capped a five-run eighth with a three-run homer as the Pittsburgh Pirates downed the Chicago Cubs, 8-4, in the rubber match of a three-game set.

Andrew McCutchen had two hits and three runs scored, while Starling Marte added a solo shot for the Pirates, who have won six of their last eight games.

Jeff Karstens (4-2) surrendered a run on three hits and a walk in five innings.

"Karstens gave us what we needed off the mound," Pirates manager Clint Hurdle said. "He threw almost 50 pitches in the first two innings, which is what I think sapped him a little bit. We put it together out of the bullpen and found a way to stay tight and scored a few more than them late."

Making their Pirate debuts after being acquired on Tuesday, Gaby Sanchez went 0-for-2 before being lifted for a pinch-hitter, while Travis Snider tallied two hits and a run scored.

The Pirates acquired the first baseman Sanchez and pitcher Kyle Kaminska from the Miami Marlins in exchange for outfielder Gorkys Hernandez and the club's 2013 competitive balance draft pick. Snider was brought in from the Toronto Blue Jays for pitcher Brad Lincoln.

Travis Wood (4-7) fanned six, but was charged with two runs on three hits and three walks over five innings for the Cubs, who have dropped two straight on the heels of a three-game winning streak.

"There were no strike ones going on," Cubs manager Dale Sveum said of Wood. "The at-bats were carrying on a little bit and he didn't have much control of his arm side to get strikes. He was just missing out there. The pitch counts got up and he got outs when he had to."

Already leading 2-1, the Pirates broke the contest open with their five-run eighth.

Josh Harrison led off with a single and McCutchen followed with a double to put men on second and third. Garrett Jones, pinch-hitting for Sanchez, singled to left, which brought home Harrison and McCutchen. After Snider singled, McKenry smacked a three-run shot to left, giving Pittsburgh a commanding 7-1 edge.

Jones' RBI double in the ninth made it 8-1 before Jeff Baker's RBI triple and Wellington Castillo's two-run blast in the home half concluded the scoring.

Earlier, Starlin Castro's solo shot in the opening frame gave the Cubs a quick 1-0 lead, but Pittsburgh went ahead after plating a pair in the third.

Marte led off and launched a blast into the basket in left-center. McCutchen worked a one-out walk, advanced to third two batters later on Snider's single and scored on a balk to give the visitors a 2-1 advantage.

Game Notes

The Pirates are 23-13 in day games this year...McCutchen has reached base safely in 40 straight games against the Cubs...Pittsburgh is an MLB-leading 40-20 over its last 60 contests...Castro's homer was his career-high 11th of the year.