OAKLAND, Calif. -- Some of the Oakland Athletics were considering a pool on how long Friday night's game with the Houston Astros would take.

"I had right around two hours," A's catcher Josh Phegley said after Oakland, behind a complete game effort from Sonny Gray, beat the Astros 3-1 on Friday night. "Both guys pound the strike zone and challenge everybody. I thought there would be a lot of quick at-bats."

Phegley, who had two hits and drove in a run, proved to be a pretty good oddsmaker. There was very little wasted effort from either side as Gray (12-4) got the upper hand of Dallas Keuchel in a game that lasted 2 hours, 20 minutes.

"They're aggressive and they hit a lot of balls hard," Gray said. "They were taking some pretty big swings and we were a little fortunate that they hit them to guys. I wanted to challenge them with my fastball and make them put the ball in play as quick as possible. Guys made some good plays behind me."

Gray improved to 5-1 over his last 11 starts by giving up one run and five hits. He struck out five and did not walk a batter in his third complete game, all within his last six starts. He won at home for the first time since beating the New York Yankees on May 29. He was 0-2 in his previous five home starts.

"It's the same every time. He's pretty consistent," Phegley said. "He uses his fastball to challenge every hitter and keeps them off balance with his slider. He's out to prove he's one of the best pitchers in the American League and he does it time and time again. He keeps an even keel."

Danny Valencia, claimed off waivers from the Toronto Blue Jays on Monday, hit his first home run with the A's and improved to 7 for 12, including two homers and two doubles, against Keuchel.

"We heard he had good numbers against him," Phegley said. "He showed it tonight."

Billy Burns had two hits and drove in a run and Marcus Semien had three hits as the A's improved to 4-3 over their past seven games.

Luis Valbuena hit his 21st home run for the Astros, who have lost four of five.

Keuchel (13-6) gave up three runs and 10 hits in 7 2/3 innings. He walked two and struck out three. The Astros had beaten Oakland the previous six times Keuchel started.

"We knew going into the game that this was going to be a pretty difficult task on both sides," Astros manager A.J. Hinch said. "They found some hits, they found some holes. I thought Dallas did a good job of holding them down a little bit."

The A's took a 1-0 lead in the second. Phegley, Semien and Mark Canha singled to load the bases. After Keuchel struck out Sam Fuld, Burns hit a sacrifice fly.

It was 2-0 when Valbuena crushed a 3-2 pitch over the fence in right field to close the gap. Phegley doubled home Brett Lawrie, who had been hit by a pitch, in the fifth for the final margin.


Astros: OF Preston Tucker (right arm contusion) was in the starting lineup Friday night after missing two games.

Athletics: OF Josh Reddick, nursing a sore back, was out of the starting lineup Friday night against Keuchel. Reddick is 1 for 15 lifetime against Keuchel. ... The A's acquired minor-league RHP Darwin Frias from the New York Mets on Friday as the player to be named in the Aug. 4 trade of LHP Eric O'Flaherty. Frias, 23 was assigned to Class-A Vermont.


Astros: RHP Collin McHugh (13-5, 4.27) has won four straight decisions. He's 2-0 against the A's with a 1.26 ERA. McHugh has recorded 18 strikeouts in 14 1/3 innings against Oakland.

Athletics: RHP Jesse Chavez (5-11, 3.88) is 1-2 with a 6.62 ERA in four starts since the All-Star break. He's 2-1 with a 3.16 ERA in 20 appearances, including four starts, against the Astros.