Updated

Giancarlo Stanton's two-out, two-run homer in the bottom of the eighth inning lifted the Miami Marlins over the Milwaukee Brewers, 5-4, in the middle game of a three-game set at Marlins Park.

Stanton crushed the first pitch he saw off reliever Jim Henderson (2-2) to put the Marlins ahead. Juan Pierre beat out an infield single to get on base with one out in front of the go-ahead blast.

"It was all set up by (Pierre) with that great at-bat, giving (Stanton) a chance to get up there and make that great swing," Marlins manager Mike Redmond remarked.

Derek Dietrich also had a two-run homer while Logan Morrison added a run- scoring double, his first RBI of the year, for the Marlins.

Aramis Ramirez, Jonathan Lucroy, Yuniesky Betancourt and Scooter Gennett each collected an RBI for the Brewers, whose four-game winning streak came to an end.

Chad Qualls (2-0) pitched a perfect top of the eighth to earn the win, while Steve Cishek picked up his seventh save of the year with a scoreless ninth.

Although he has just one win in his last seven decisions, Brewers starter Wily Peralta had an effective outing, surrendering three runs on five hits over six innings.

Miami starter Jacob Turner was dinged for four runs -- three earned -- on five hits with six strikeouts over six frames in his third start of the season. In his first two, he allowed just one run in 13 innings.

The Marlins struck first in the second. Marcell Ozuna sent a shot up the middle and Morrison drove the speedster in with an RBI double to center. Dietrich then slammed a two-seam fastball to the upper deck in right field to grab an early 3-0 lead.

Milwaukee took advantage of Miami's mistakes in the fourth. Carlos Gomez struck out swinging to start the inning but was safe at first on a wild pitch. After three pickoff attempts, the fourth was costly, getting past first baseman Morrison and allowing Gomez to reach third. Lucroy brought in the run with a sacrifice fly.

Jean Segura singled in the sixth and stole second to get himself into scoring position. Gomez and Ramirez hit back-to-back groundouts, respectively, to cut the deficit to one.

The Brewers used a two-run seventh inning to take a 4-3 lead.

Betancourt hit a one-out triple that was misplayed by right fielder Stanton to score Rickie Weeks, who worked a walk. Gennett delivered a perfectly placed sacrifice bunt down the third baseline to bring in Betancourt.

"I just wanted to make sure that I got the correct sign and I was relaxed and put myself in the best position to execute," Gennett said of his bunt.

Game Notes

Milwaukee's Ryan Braun missed his second straight game with a thumb injury ... The Brewers have gone a season-high eight consecutive games without committing an error ... Pierre extended his hitting streak to eight games ... Norichika Aoki's 11-game hitting streak was snapped, along with his 72 consecutive plate appearances without striking out ... Milwaukee was 0-for-4 with runners in scoring position ... Cishek has not allowed a run in 10 career games against Milwaukee.