HOUSTON -- Miguel Tejada has been able to be patient at the plate this season knowing who's hitting behind him.
The Astros shortstop is hitting in front of Lance Berkman, who is having a stellar season with 28 homers and 100 RBI.
"I try to be the most relaxed I can be because I know I have the hottest player in baseball behind me -- Lance," Tejada said. "I have so much confidence in Lance right now, that I'm not looking for a walk or a base hit.
"That's why I'm taking pitches. Right now, I want him to come to the plate with the bases loaded. I was just trying to get one (run in)."
Houston has won five straight and 13 of 14 and remains four games behind Milwaukee in the wild-card chase. The Astros are now 12 games over .500 for the first time since the end of the 2005 season, when they finished 16 games over .500.
Brian Moehler (11-6) went six innings and allowed two runs on five hits.
"Moehler did a good job," Houston manager Cecil Cooper said. "He throws strikes. He was around the zone. I don't even think he had his best stuff but he was able to keep us close."
Jose Valverde pitched the ninth for his league-leading 42nd save in 48 tries. He stretched his franchise record for consecutive saves to 15.
Denny Bautista (4-3) pitched 1 1/3 innings and gave up five runs and three hits.
"Again, we're not hitting our spots when we need to," Pirates manager John Russell said of Bautista. "We put guys on the base against a good hitting team. His velocity is still there, he just didn't have his breaking ball tonight. It was still a good matchup (with Tejada) if he throws the ball the way he is capable."
With the score tied 2-2, Darin Erstad's bases loaded sacrifice fly drove in the go-ahead run in the sixth. A walk to Mark Loretta then set up Tejada's slam. It was Tejada's 11th career grand slam and 13th homer of the season.
Starter Tom Gorzelanny had to leave the game in the third inning with an irritation to his left middle finger. Gorzelanny went 2 1/3 innings and allowed two runs on three hits and two walks. He struck out two.
Houston took a 2-0 lead on Hunter Pence's two-run homer in the second inning. It was his 22nd home run of the season.
Pittsburgh cut the deficit to one on Adam LaRoche's 19th homer of the year in the fourth inning. The Pirates tied it in the fifth on Nyger Morgan's RBI double.
They closed to 7-4 on RBI doubles by Nate McLouth and LaRoche in the eighth inning.
- The Astros are considering whether to change the time of their game with the Chicago Cubs Friday from 7:05 p.m. to 1:05 p.m. because of the possibility of Hurricane Ike heading toward the city. A final decision will be announced Thursday morning or afternoon. Officials say the possibility of moving Saturday's game for the same reason will be determined later.
- Tejada's double in the fifth inning gave him an 11-game hitting streak.
- Tejada's slam won $25,000 for Astros fan Linda LeBlanc, whose name was chosen at random to win the money if Houston hit a grand slam in the inning.
- Lance Berkman scored his 110th run of the season matching his career high set in 2001 and 2003.
- Reggie Abercrombie's three hits tied his career high for the fifth time, most recently Sept. 6 at Colorado.
- Valverde's 42nd save is tied for second in Astros history with Brad Lidge in 2005.