Cardinals: Sonny Gray pitched seven innings of two-hit ball, and the Cardinals beat the slumping Pirates 5-0 on Wednesday in St. Louis for their fifth straight victory. Gray (4-1) struck out eight and walked one in his first win since April 14. The right-hander went 0-1 with a 5.51 ERA in his previous three starts. The Cardinals returned to .500 at 19-19, including a 15-6 record at home. They’re 4-2 against the Pirates this year after finishing a three-game sweep. Masyn Winn hit two RBI doubles. Lars Nootbaar had three hits, and Victor Scott II scored all the way from first twice. The Pirates (12-26) were shut out for the eighth time. They have lost seven in a row and 10 of 11 overall. The Cards jumped in front with two runs in the third against Mitch Keller (1-4). Scott walked and scored on Nootbaar’s hit-and-run single to right. Winn added a bloop RBI double. Scott extended his hitting streak to a career-high eight games when he hit a leadoff single in the fifth. He scored on Winn’s one-out double. Jordan Walker added a two-run single in the eighth. Keller allowed seven hits in six-plus innings. He struck out six and walked three. The Pirates finished with four hits. Nolan Arenado was scratched from the the Cardinals lineup with back spasms.

Astros: Slugger Yordan Alvarez has a strained muscle at the top of his right hand, a diagnosis that instills optimism he won’t have a prolonged stay on the IL. The three-time All-Star went on the 10-day IL on Monday, retroactive to Saturday, and returned to Houston for an MRI that revealed the muscle strain. “We look at it as good news,” Astros manager Joe Espada said before their 9-1 victory against the Brewers on Wednesday afternoon. Espada expressed hope that Alvarez wouldn’t have to stay on the IL longer than the required 10 days. He also said the hand issue may have played a role in Alvarez’s slow start. Alvarez, 27, is hitting .210 with a .306 on-base percentage, three HRs and 18 RBIs in 29 games this season. He batted .308 with a .392 on-base percentage, 35 HRs and 86 RBIs in 147 games last year while ranking ninth in the AL MVP balloting. He has posted an OPS of at least .959 and has finished 13th or higher in the MVP voting each of the last three seasons. “Once he heals, once he gets back, I think we’ll see a more aggressive at bat and be not as cautious,” Espada said. “I think it had something to do with it, yes.”

Cubs: Robbie Ray pitched six sparkling innings, Wilmer Flores had three hits and the San Francisco Giants beat the Chicago Cubs 3-1 on Wednesday.Ray (5-0) allowed one run and three hits in his second straight win. Camilo Doval and Tyler Rogers each got three outs before Ryan Walker handled the ninth for his seventh save. San Francisco took two of three at Chicago to improve to 24-14. The Giants scored nine runs in the 11th inning in a wild 14-5 victory over the Cubs on Tuesday night.Nico Hoerner had two of Chicago’s four hits. Ben Brown (3-3) struck out nine in five innings, but was charged with three runs and six hits.