HOUSTON -- J.D. Martinez has made some small changes at the plate that have helped him find his swing and get Houston's offense rolling.
Martinez has eight RBIs and three homers in the last four games, a big reason the Astros have busted loose with the bats. They have 10 homers and 27 runs in those games, after scoring just one run in the previous three games combined.
"He's getting back into that hitter that we all saw last year and that's nice to see," Houston manager Brad Mills said. "He's on a little roll here and we surely hope that can continue."
Mills and Martinez had a talk and watched some video of him at the plate at the beginning of this homestand in an attempt to improve his approach. Martinez said he's feeling good and not missing his pitches lately.
"I just feel happy that I was able to contribute and make an impact on the game," he said. "It's always what you want to do. You want to make a difference -- anything you can do to help the team win."
Houston starter Jordan Lyles (2-4) allowed six hits and a run in 6 1/3 innings to break a three-game losing streak and earn his first victory since June 3.
"It was nice to see Jordan get some reward," Mills said. "He's been throwing the ball extremely well for us. He just wasn't as crisp as he has been, but he just picked it up as he went along."
The game was tied at 1 after Will Venable and Lowrie exchanged solo homers in the third.
Wells became the 13th different starter in San Diego's revolving-door rotation by making his first major league appearance since 2009. Wells, signed to a minor league deal May 7, yielded seven hits and five runs -- two earned -- in five innings.
Venable hit a ball that bounced off the top of the wall in right field and back onto the field for what was first called a triple to start the third inning. The play was reviewed and Venable had his sixth homer to put San Diego up 1-0.
Lowrie evened things up with his team-leading 14th home run to start Houston's third inning. The ball dropped into the Astros bullpen in right-center, where reliever David Carpenter had to scramble to avoid being hit by it.
That wasn't the only action of the night for Carpenter, who allowed a single and a walk before being replaced by closer Brett Myers with one out in the ninth. Chase Headley's two-run single with two outs got San Diego within 5-3.
The 35-year-old Wells was having a decent night before the fifth inning, considering he hadn't pitched in the majors since Oct. 1, 2009, when he allowed five runs in two-plus innings of a 13-0 loss to St. Louis with the Reds. He was called up from Triple-A Tucson for Tuesday's start.
Lowrie started the fifth with a single and went to third on an error by Wells, who overthrew second base on Brian Bogusevic's one-out comebacker.
Wells was disappointed in himself for making the error.
"At times as a pitcher, you don't realize you have more time than you think, so get your feet under you and make a good throw so you don't get in a hurry," Wells said.
The Astros took a 2-1 lead when Lowrie scored on a wild pitch before Johnson's run-scoring single, which extended his hitting streak to seven games.
Then came Martinez's 10th home run of the season to push Houston's lead to 5-1.
Lyles got into trouble in the second when Baker reached on an error by Johnson with one out before consecutive singles by Cabrera and Amarista loaded the bases. But Lyles retired the next two batters to work out of the jam.
The Padres left the bases loaded three times, one night after the Astros did the same thing in an 8-7, 10-inning loss.
"It's frustrating," Padres manager Bud Black said. "We were looking for one big knock ... and we couldn't get the knock."
The Padres began wearing patches with No. 48 on their uniforms in honor of longtime bullpen coach Darrel Akerfelds, who died of pancreatic cancer on Sunday. ... Houston 2B Jose Altuve was out of the lineup for the second straight game with a strained right hamstring. ... The Padres recalled Nick Vincent from Double-A San Antonio and optioned INF Andy Parrino and RHP Brad Boxberger to Tucson. They also moved RHP Joe Wieland (strained right elbow) from the 15-day disabled list to the 60-day DL. ... Houston placed OF Justin Maxwell on the 15-day DL with a left ankle injury and purchased the contract of INF Scott Moore from Triple-A Oklahoma City. ... The Astros reinstated OF Travis Buck from the DL and designated him for assignment, and reinstated OF Fernando Martinez from the DL and optioned him to Oklahoma City. ... The Padres signed OF Travis Jankowski, the 44th pick in this year's amateur draft, and 11th-round pick INF Maxx Tissenbaum. ... Houston signed second-round pick Nolan Fontana.