PHOENIX (AP) -- The Arizona Diamondbacks' euphoria following a three-game sweep in Milwaukee evaporated in a sputtering home loss to the Pittsburgh Pirates.
Trevor Cahill struggled through five innings and three Pittsburgh relievers held the Diamondbacks hitless through the final five in the Pirates' 5-3 victory Monday night.
Cahill, who has both of Arizona's losses through seven games, allowed four runs and four hits in five innings. He struck out seven but walked four and hit a batter with a pitch.
"He didn't throw the ball where he wanted to at all," manager Kirk Gibson said. "He walked a couple of guys, he hit a guy, he was behind. The triple that (Starling) Marte got was a 2-0 pitch. He didn't throw the ball good at all, not hitting his location, so they got on us. We can't score five runs every night."
Cahill said he never could find the proper arm slot.
"I felt I couldn't command my fastball," he said.
Pittsburgh scored three times in the first, but Arizona rallied to tie it at 3 before the Pirates went ahead for good on Marte's triple, followed by Andrew McCutchen's sacrifice fly in the fifth. Garrett Jones added a solo home run off Josh Collmenter in the eighth.
McCutchcen also doubled in a run and Travis Snider singled in a pair as the Pirates snapped a five-game losing streak. Pittsburgh had managed just eight runs in its first six games.
Marte, who was 2 for 4 with two runs, and McCutchen make for an exciting pair, manager Clint Hurdle said.
"They're fun to watch at the plate," he said, "and they're fun to watch on the bases."
Jeanmar Gomez (1-0) got the victory in relief of Rodriguez, who left after 2 1-3 innings because of tightness in his left hamstring.
Cahill (0-2) allowed four runs and four hits in five innings for the Diamondbacks, who had won four in a row and were trying to go 6-1 for only the second time in franchise history.
Alfredo Marte drove in a run for Arizona with his first major league hit.
Jason Grilli pitched a scoreless ninth for his second save.
Arizona's Paul Goldschmidt had a sacrifice fly, giving him an RBI in a career-best five straight games, but the Diamondbacks didn't get a hit in the last five innings. Justin Wilson threw three innings of hitless relief before Mark Melancon and Grilli closed it out.
Wilson was the most impressive.
"Prado-(Aaron) Hill-Goldschmidt, that's a litmus test for any left-hander," Hurdle said. "That's the most velocity I've seen him have and his breaking ball was good. He's going 98 (mph), 79 (mph), and throwing strikes. Not a single three-ball count."
The Pirates, who hadn't won since opening day, got to Cahill in a hurry.
Starling Marte opened the game with a single, then scored when McCutchen doubled down the left-field line. With two outs, Cahill walked Russell Martin and Pedro Alvarez to load the bases, and Snider followed with a two-run single.
Arizona got one back when Goldschmidt doubled to deep left and scored on Wil Nieves' two-out single.
Two unearned runs for the Diamondbacks tied it at 3 in the third.
Gerardo Parra reached on an error by Alvarez at third base for running in front of shortstop Clint Barmes, impeding his ability to field the ball. That's when Pirates trainers rushed to the mound and, after trying to stretch and throwing a practice pitch, Rodriguez left the game and Gomez came in.
Rodriguez said he felt the hamstring tighten up on his next-to-last pitch to Parra.
Martin Prado singled and Aaron Hill walked to load the bases for Goldschmidt, who narrowly missed a grand slam on a deep drive to left for a sacrifice fly. With two outs, Alfredo Marte drove in the tying run with a single.
The Pirates, who entered with a .119 batting average in their first six games, went back up 4-3 in the fifth when Starling Marte tripled into the left-field corner and scored on McCutchen's sacrifice fly.
Jones' home run to right came on a 2-2 pitch from Collmenter and made it 5-3.
NOTES: With a storm front moving through the area, the roof at Chase Field was closed. ... Alfredo Marte's hit came in his seventh at-bat. ... In the second game of the series Tuesday night, the Pirates send RHP James McDonald (0-1) to the mound against RHP Brandon McCarthy (0-0). ... Pittsburgh had not scored more than three runs in any of its first six games and managed just two runs total while being swept by the Dodgers in Los Angeles last weekend. ... Arizona LHP Matt Reynolds has allowed one hit in five scoreless innings this season. ... The Pirates homered for the second straight game after hitting none in their first five.