PHOENIX (AP) -- The Colorado Rockies figured it was only a matter of time until their high-powered offense started producing.
"We've got a good team and I think we're going to put it together here very soon," said Barmes, who came off the bench to drive in four runs. "I think today was a big start. It was definitely one that we needed."
Holliday and Atkins knocked in three runs apiece for the Rockies, who beat their NL West rivals for the first time in six meetings this year.
Colorado beat the Diamondbacks 10 of the last 12 meetings a year ago, including four straight in the NL championship series. But the Rockies had dropped the first five meetings this season by a combined 38-10, and they entered Sunday 5 games behind the division-leading Diamondbacks.
Still, manager Clint Hurdle rejected the notion that his team played with a sense of desperation on a bright, 89-degree day in the desert.
"There is no must-wins in April," Hurdle said. "We've been around the block a couple times. Now, we have a good team. There's a lot of people that still don't think we have a good team. I can tell by the questions I get asked. But by no means did we feel there was desperation. We've just got to play like we're capable of playing.
"We've proven ourselves to a certain extent," Hurdle said. "We didn't get out of the blocks the way we'd like. That does not mean we're not going to come back. We'll be heard from again."
The Diamondbacks had drubbed Colorado 8-2 and 10-3 in the first two games of the series. But they suspected that the Rockies would eventually break out of their slump.
"Colorado's a good team," said center fielder Jeff Salazar, who had a triple and tied a career high with three RBIs. "You're not going to shut them down for too long."
The Rockies piled up plenty of support for starting pitcher Aaron Cook. Cook (1-1) went six innings, allowing three runs on eight hits. He walked three and struck out four.
Cook said he was able to use offspeed pitches to complement his trademark sinker. He threw 96 pitches -- 57 for strikes -- before giving way to the bullpen.
"I threw more pitches than I have liked after six innings," Cook said. "But it worked out and I'll take the win any time."
Cook went to the mound for the first time with a 2-0 lead.
"Good day for Barmes," Hurdle said. "It's one of the best things in baseball when you see one of your guys come off the bench and respond like that."
Arizona manager Bob Melvin lifted Gonzalez after only three innings. Gonzalez, the Diamondbacks' fifth starter, gave up three runs on five hits. He walked two, hit two and struck out one.
Melvin said Gonzalez was "a little bit sick." A team spokesman said it was an infected tooth.
"He got a little dizzy out there," Melvin said. "That's why he had to come out of the game. So he was fighting that early on. He didn't have his best stuff. The ball was up in the zone. That probably had something to do with it."
Gonzalez left without speaking to reporters.
Salazar hit a two-run triple in the sixth to pull the Diamondbacks to 5-3. But the Rockies responded with two runs in the seventh and eighth and four more in the ninth.
"It was nice to throw some punches back offensively," Hurdle said.
The Diamondbacks hit four batters, tying a club record. ... Arizona LHP Randy Johnson, who is returning from back surgery, will make his regular-season debut on Monday night at San Francisco. Manager Bob Melvin said he won't have the Big Unit on a pitch count. Johnson went 4-3 with a 3.81 ERA for Arizona last season. ... Colorado's Matt Herges, Taveras and Torrealba will all wear No. 42 on Tuesday at San Diego to honor Jackie Robinson.