PHOENIX -- Close is no consolation for the slumping Houston Astros.
Brandon Webb limited Houston to two runs through seven innings and the Arizona Diamondbacks held on to hand the Astros their seventh loss in a row, 5-4 on Saturday night.
"We played a good game," Houston manager Phil Garner said, "but right now we could use a sloppy game and a win."
Webb (4-3) scattered seven hits, struck out eight and walked one to help the Diamondbacks beat Houston for the third straight game. The reigning Cy Young winner threw 98 pitches, 73 strikes. Only two outs against the sinker-ball specialist were fly balls.
Webb survived a scare when he took a line drive from Lance Berkman off his left forearm in the sixth inning.
"As soon as it hit me it hurt right off the bat," Webb said. "I kind of thought my arm was broken for a second. Then I waited around a little bit and it kind of subsided and it wasn't too bad at all."
Catcher Chris Snyder was as concerned as anybody when he saw the liner hit the Diamondbacks ace.
"That ball was hit hard," Snyder said. "I didn't know where it hit him. I was hoping he got glove on it. Fortunately for everybody it was his non-throwing arm."
With Arizona up 3-2 in the seventh, Eric Byrnes drove in two runs with a bases-loaded double over the head of left fielder Carlos Lee off Chad Qualls.
"I was trying to go down and in and I missed right down the middle," Qualls said. "That's basically the pitch that keeps repeating in my mind."
Snyder doubled in a run off Houston starter Chris Sampson (4-5) in the second. Mark Loretta was 3-for-4 with a double and run scored for the Astros.
Lee hit a first-pitch, two-out home run off Tony Pena to drive in two in the eighth and cut the lead to 5-4. Lee has 10 homers and 43 RBI this season.
Jose Valverde pitched a scoreless ninth for his major league-best 18th save in 20 opportunities.
After Houston tied it at 2-2 with a run in the top of the sixth, the Diamondbacks regained the lead for good in the bottom half of the inning.
Orlando Hudson tripled with one out, then scored on Tony Clark's towering sacrifice fly caught by Hunter Pence at the top of the right-field fence.
Houston got one in the first when Mike Lamb beat out third baseman Mark Reynolds' throw for a leadoff single. Lamb advanced to third on a hit-and-run single by Loretta, then scored on a fielder's choice by Berkman.
Sampson retired the first six Arizona batters before Carlos Quentin led off the third with a single, then scored on Snyder's double to the right-center gap. Webb bunted Snyder to third, and Chris Young's sacrifice fly put the Diamondbacks up 2-1.
Loretta doubled to lead off the sixth, then advanced to third on Berkman's line drive off Webb. After a visit from the Arizona training staff and manager Bob Melvin, Webb stayed in the game.
"At the time he felt OK because it was still kind of numb," Melvin said, "and then it started to swell up a little bit on him, and after the seventh inning it was time to go."
Lee's sacrifice fly brought Loretta home to tie it at 2-2.
Sampson allowed three runs and four hits in six innings, striking out two and walking three.
"Looking back on it, I made three mistake pitches," he said. "The way this team (the Diamondbacks) are swinging the bat right now, they're hot and you just can't make any mistakes. The way they're swinging it, they're capitalizing on everything."
After scoring one run in two games against Colorado, the Diamondbacks have 27 in three games against Houston.
"Right now we're just trying to ride it out," Snyder said, "and get as many of these wins as we can."
The Diamondbacks go for a four-game sweep of Houston on Sunday against Roy Oswalt, who is 6-0 with a 1.98 ERA in seven starts against Arizona.
The Diamondbacks lead the majors in sacrifice flies with 26. ... A three-man crew umpired the game because Jerry Crawford was out because of "medical issues." ... Craig Biggio struck out four times, three by Webb. ... Young had missed six of the last seven games with a sore groin.