MILWAUKEE (AP) — Sal Frelick homered for the first time this season, Joe Ross and three relievers combined on a three-hitter, and the Milwaukee Brewers beat the Pittsburgh Pirates 4-3 on Tuesday night.

Pittsburgh’s Nick Gonzales hit his first homer of the year, and Connor Joe also went deep for the Pirates.

Gonzales’ last homer was July 2, and Frelick hadn’t homered since Aug. 7.

Frelick also made two diving catches in center field. He caught a sinking liner from Jared Triolo to end the second and made a play on the warning track to rob Andrew McCutchen of an extra-base hit in the eighth.

“That’s the kid that has got the ‘it’ factor,” Brewers manager Pat Murphy said. “We’ve thrown a lot at him since he’s been here. He’s got that. Really, really happy for him.”

Joe homered with two outs in the ninth off Trevor Megill to cut Milwaukee’s lead to 4-3, but Megill struck out Jack Suwinski to earn his fifth save.

Ross (2-4) struck out six while allowing two hits, two runs and one walk in five innings. Bryan Hudson pitched two innings and Elvis Peguero worked the eighth without allowing anyone to reach base.

“You get to the back end of their bullpen, and it’s really good,” Pirates manager Derek Shelton said. “Hudson came in, and he’s funky and did a good job. You get Peguero and Megill at the end, those are two power arms, they don’t give up a lot of hard contact.”

Brewers pitchers had retired 15 straight Pirates before Joe’s homer.

After each team left runners on the corners in the first inning, the Brewers took the lead for good by scoring all four of their runs in the second.

The Brewers collected five straight hits against Quinn Priester (0-4) during one stretch in that inning. Joey Ortiz got things started with a one-out double before Frelick lofted an 0-1 slider over the right field wall.

Oliver Dunn, Jackson Chourio and Brice Turang then delivered three consecutive singles, with Turang’s hit driving in Dunn. Christian Yelich’s two-out single brought home Chourio to make it 4-0.

“It’s just contagious,” Frelick said. “It really is. I’ve felt it when I’m hitting behind guys who, they’re are all on base, they all get hits. The pitcher kind of falls into an ‘Oh, no’ kind of mentality, and guys are just fighting to get to the bat racks. I think that inning just encapsulated that.”

Gonzales cut Milwaukee’s lead in half with his two-run shot in the fourth.

Priester lasted six innings and gave up four runs and nine hits. He struck out five and walked two.

“I needed to do things better in that second (inning) and keep it close and give our guys a chance,” Priester said. “But after that, I was proud of how I settled in and battled.”

TRAINER’S ROOM

Pirates: Domingo Germán allowed a run over four innings for Single-A Bradenton in the former New York Yankees pitcher’s first appearance since signing a minor league deal with the Pirates in March. Germán threw the 24th perfect game in major league history in New York’s 11-0 victory at Oakland last June 28, but he was placed on the restricted list and entered treatment for alcohol abuse later that summer.

Brewers: 1B Rhys Hoskins went on the 10-day injured list with a strained right hamstring. The Brewers promoted utilityman Owen Miller from Triple-A Nashville to fill Hoskins’ spot on the roster. … Brewers LHP DL Hall (left knee) threw 35 pitches in a simulated game Tuesday.

UP NEXT

LHP Martín Pérez (1-2, 3.60) starts for the Pirates and LHP Robert Gasser (1-0, 0.00) pitches for the Brewers as this three-game series concludes Wednesday afternoon.