DENVER -- Michael Cuddyer's injury-plagued season is finishing on a high note.
"When he's been out there, he's showing he's still an elite hitter in this game," Rockies manager Walt Weiss said. "He gets the barrel of his bat to the ball with impact."
Cuddyer, whose contract with the Rockies expires after this season, has endured three stints on the disabled list, missing 99 games, twice because of a left hamstring strain and the other because of a left shoulder fracture.
Rather than dwell on the playing time that he lost, Cuddyer said he's focused on closing the season out well since being reinstated Sept. 8 from his last stint on the DL.
"You can't control any of that stuff, obviously," the 35-year-old Cuddyer said. "I didn't want to get hurt. I didn't try to get hurt, but I did. To think of what might have been, you're just doing yourself a disservice. There's no point in doing that. The only thing you can do when you get out there on the field is play hard and hopefully things go your way."
That philosophical approach paid off for him at the plate and helped Jordan Lyles, who pitched six strong innings, get his first win in six weeks.
"When you're coming out of the game and Cuddy hits the grand slam, that was a fun inning," Lyles said. "It was good as a starting pitcher, when you come out the game and we up a couple more runs, more than a couple."
Rafael Ynoa added four hits and three RBIs and Wilin Rosario had three hits and two RBIs for the Rockies, who moved a game up on last-place Arizona in the NL West. It's the first time Colorado hasn't been in last place, either alone or shared, since July 13.
Lyles (7-3) gave up two runs and nine hits with one strikeout, consistently getting ground-ball outs en route to his first win in eight starts since Aug. 6.
Chase Anderson (9-7), trying to become the fifth Diamondbacks rookie with at least 10 wins in a season, allowed six runs and nine hits in five innings.
"I had a good fastball today and once I got ahead I put some guys away and other guys I didn't. I wish I could have done that," Anderson said.
The Rockies were leading 7-2 in the sixth when reliever Eury De La Rosa hit Justin Morneau with pitch to load the bases with one out. Cuddyer worked the count to 2-2 before driving De La Rosa's pitch deep into the left-field bleachers for his eighth career slam and first since May 30, 2012, against Houston. It was the fourth slam by a Rockies player this season and marked the 20th consecutive game in which Colorado has homered.
Cuddyer came up with the bases loaded again in the eighth and lined a three-run double to the gap in left-center. He's the first Rockies player with seven RBIs in a game since Jason Giambi on May 19, 2011, against Philadelphia.
Both Cuddyer and Rosario homered the night before in Colorado's 7-6 win over Arizona with Rosario delivering a two-run game-ender in the ninth.
Ynoa just missed an inside-the-park homer, settling for a two-run triple in the fifth when he was tagged out at home by Miguel Montero on a beautiful inning ending relay from second baseman Chris Owings.
Diamondbacks: RHP Bronson Arroyo, who was injured in mid-June and later underwent reconstructive elbow surgery, was transferred to the 60-day disabled list.
Diamondbacks:RHP Trevor Cahill (3-11) is slated to pitch Saturday night's Game 3 of a four game set against the Rockies. He's given up three or fewer runs in eight of his past 11 starts.
Rockies: RHP Eddie Butler (0-1) is scheduled to make his second career start Saturday night and first since taking the loss in his big league debut against the Dodgers on June 6. Butler was placed on the DL a day later because of right shoulder inflammation, missing five weeks and making two minor league rehab starts. He was recalled from Double-A Tulsa earlier this week.