The 28-year-old rookie hit for the cycle and drove in five runs, but Luis Gonzalez doubled in the 11th inning off Andy Pettitte and scored on Johnny Estrada's sacrifice fly to lift the Diamondbacks to an 8-7 victory.
Scott became the first Astros rookie to complete the cycle, a feat that included a three-run homer. He was the sixth Astros player to do it and the first since Craig Biggio in 2002.
"It's a pretty awesome thing, now that I think about it," Scott said. "I enjoyed it, but I would've really enjoyed it more if we had won."
Scott singled with two outs in the 11th to finish a 4-for-6 night. He's the first rookie to hit for the cycle since Eric Valent did it for the New York Mets against Montreal in July 2004.
"You think about it," Scott said of his accomplishment, "but at the same time, a home run can win the ballgame. I'd much rather have a home run (in that situation) than a single, double or triple."
Houston lost for the 12th time in 17 games and fell seven games under .500 for the first time this season.
"We had some great at-bats tonight; we hit the ball good several times with men in scoring position," said Houston manager Phil Garner. "Still, we didn't win the ballgame, so that's no consolation."
The Astros rallied three times to tie and sent it to extra innings on Mike Lamb's sacrifice fly in the eighth inning off Brandon Lyon.
But Pettitte (9-11) failed in his first relief appearance since 1998 with the Yankees. In his last start, on Wednesday, he gave up 11 hits in an outing he called "pathetic," though he still got the win. He gave himself another harsh grade on Friday.
"I had a chance to come in and get three outs and I couldn't do it," Pettitte said. "It's disappointing to lose this one."
Gonzalez, who also had an RBI single, hammered Pettitte's second pitch off the left-field wall. Chad Tracy grounded out before Estrada sent a towering fly ball to left, scoring Gonzalez.
The Arizona dugout was surprised to see Pettitte enter the game, though Gonzalez said the Diamondbacks took note when Pettitte started throwing in the bullpen.
"We looked out and saw him warming up and said, 'Who's that left-hander?'" Gonzalez said. "We didn't expect Pettitte, but then we saw it was No. 21. Definitely, Garner caught us off-guard with that one."
Houston starter Brandon Backe gave up a hit in each of the first three innings and the Diamondbacks jumped to their first lead in the third.
Gonzalez and Tracy had consecutive RBI singles in the first and Jackson blooped a two-out RBI single to left in the second for a 3-0 lead.
Scott hit a 2-0 pitch from Arizona starter Enrique Gonzalez just over the left-field wall for his first career homer to tie it at 3-3 in the fourth.
"We had that game in good position," said Arizona manager Bob Melvin. "All of a sudden, he ties it up with one swing and changes the whole game."
Tracy led off the fifth with a double. Shawn Green singled to right and Scott bobbled it, allowing Tracy to score easily.
The Astros answered again when Aubrey Huff doubled in the fifth and Scott hit an RBI triple, the first of his career, over Jeff DaVanon's head in center.
Luis Gonzalez said the Diamondbacks overlooked Scott in their pre-game scouting reports.
"Before the game, he was off the radar, flying low," said Gonzalez. "But congratulations to him -- that's not easy to do. I guess tomorrow, we'll go over him a little more."
In the sixth, Jackson's double to the right-field wall drove in a run and prompted Garner to pull Backe for Russ Springer.
Backe, making his second start since missing 88 games with a right elbow sprain, gave up 12 hits -- four of them doubles.
Quentin, pinch-hitting for Enrique Gonzalez, hit the first pitch he saw from Chad Qualls into the left-field seats for his fourth homer of the season, making it 7-4.
Qualls hadn't allowed a run in 18 innings and had the lowest ERA of any pitcher with at least 15 innings pitched since June 25.
Scott drilled a double down the right-field line, scoring Huff, and Brad Ausmus followed with a run-scoring groundout to cut the lead to 7-6.
Lyon replaced Brandon Medders in the eighth and Willy Taveras started the Astros last rally by beating out a bouncer to Stephen Drew. Biggio singled before Lamb's sacrifice fly tied it.
- Scott was called up from Triple-A Round Rock on July 14 after hitting .299 with 20 home runs in 318 minor-league at-bats. He had only two RBI in his first 10 games with the Astros this season.
- Tracy recorded his team-leading 33rd multi-hit game.