HOUSTON -- In a stretch where the Arizona Diamondbacks feel like things haven't been going their way, a lucky break on Friday night helped them to a much-needed win.
The AL West-leading Astros had their edge cut by Oakland to 2 1/2 games. Arizona moved within three games of St. Louis and Los Angeles for the second NL wild-card spot.
It was 2-all when Nick Ahmed doubled off Hector Rondon (2-4) with one out in the Arizona eighth. Jay hit a two-out, tiebreaking drive into the right field corner and later scored when a flyball by A.J. Pollock dropped in shallow center field for a single.
The triple by Jay came on a ball he said hit twice off his bat and that he thought was probably going to be foul.
"It kind of hooked back and that's when I realized what had happened and I just ran," Jay said. "It fell through and ... that was a big break for us right there. We needed it."
Manager Torey Lovullo was impressed with the way his team persevered.
"I know that we've been dealing with some frustrating circumstances," he said. "For us to come out against the world champs and play the way we did, I was really proud of these guys."
Arizona starter Robbie Ray yielded two hits and two runs with six strikeouts in 5 1/3 innings. Brad Ziegler (2-6) pitched 1 1/3 scoreless innings and Yoshihisa Hirano allowed one hit in a scoreless ninth for his second save.
Astros starter Dallas Keuchel allowed five hits and two runs in six innings.
Ray retired 13 of the last 14 batters he faced with Houston's only baserunner in that span coming when he walked Carlos Correa with one out in the fourth.
"It was frustrating," manager A.J. Hinch said. "We didn't do a ton between the first inning and the sixth inning, offensively. Ray settled in and flashed his good stuff. We did get a couple of opportunities but just couldn't break through with the big hit."
The Diamondbacks scored twice in the first when Eduardo Escobar walked, Goldschmidt hit a ground-rule double and Peralta followed with a single.
Houston came back with two in the bottom half. George Springer led off with a single, Jose Altuve and Alex Bregman walked to load the bases and Yuli Gurriel hit an RBI single. A double-play grounder by Correa tied it.
Diamondbacks: RHP Clay Buchholz, scratched from his scheduled start on Thursday with tightness in his right elbow, has a flexor strain in his right forearm and Lovullo said after the game that he won't pitch again this season. He added that he'd have more information about his condition in the coming days. ... LHP T.J. McFarland has inflammation of a bone spur around his elbow, but Lovullo said he doesn't think that it will keep him out long.
TRIPLES ON TRIPLES
Jay's triple was his fifth with the Diamondbacks this season and seventh overall. It also gave Arizona 46 triples this season which leads the majors.
SIPP KEEPS STRANDING
Houston left-hander Tony Sipp struck out David Peralta with two runners in scoring position in the seventh inning on Friday night. He's now stranded 31 of 35 runners he's inherited this season, which is the third-highest percentage in the majors.
Houston's Charlie Morton (14-3, 3.15 ERA) opposes Arizona's Zack Godley (14-9, 4.67) when the series continues Saturday night. Morton has won two straight and tied his career high for wins. Godley has dropped two in a row and allowed seven hits and five runs in four innings of a loss to the Rockies in his last start.
More AP MLB: https://apnews.com/tag/MLB and https://twitter.com/AP-Sports
Mondesi 464-foot HR helps Royals beat Boston 5-3, stop skid
— Adalberto Mondesi hit a 464 foot three-run homer, Salvador Pérez added his 18th home run this season, and the Kansas City Royals beat the Boston Red Sox 5-3 on Friday night for only their second win in their last 13 games.
Rockies walk it off on C.J. Cron's single
C.J. Cron sends the Colorado fans home happy with a walk-off single as the Rockies top the Brewers 6-5 in 10 innings.
Twins' triple and 2 bases-loaded walks in 10th beat Texas
— Luis Arraez hit an RBI triple to start the Minnesota 10th inning and the Twins then drew two bases-loaded walks to beat the Texas Rangers 7-5 on Friday night in the opener of a three-game series matching last-place teams.
Twins score 3 in the 10th to beat the Rangers
An RBI triple from Luis Arraez and two bases-loaded walks power the Twins to a 7-5 win over the Rangers in 10 innings.
Adolis Garcia sends 100 mph pitch into the seats
Adolis Garcia's first home run in June, his 17th of the season, ties the game for the Rangers against the Twins.
Adam Duvall's grand slam highlights 3-HR game for Marlins
Adam Duvall hits a grand slam and a 2-run shot, while Jon Berti chips in a 3-run shot helping the Marlins dominate the Cubs 10-2.