Updated

OAKLAND, Calif. (AP) Josh Phegley had two hits and drove in a run, Danny Valencia hit a home run and Sonny Gray won a pitching duel with Dallas Keuchel as the Oakland Athletics beat the Houston Astros 3-1 on Friday night.

Gray (12-4) 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.

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.