For a man who could do without the accompanying attention Diamondbacks first baseman Paul Goldschmidt sure does seem to thrive in big moments.

Goldschmidt hitting .190 with 14 strikeouts in his previous 11 games hit a laser of a solo home run in the bottom of the ninth inning to lift the Diamondbacks to a 5-4 walkoff win over the New York Mets on Saturday in front of 25187 at Chase Field.

Goldschmidt was 0 for 2 with two walks and two strikeouts before coming to the plate in the ninth.

“His at-bats earlier didn’t work out the way he wanted them to but that one did” manager Kirk Gibson said. “That was pretty impressive. That was a bullet.”

The home run was Goldschmidt’s 27th of the year breaking the club record for homers by a first baseman set by Tony Clark in 2005. It was also the Diamondbacks’ second win in their last at-bat in as many games giving them a major-league-leading total of 23 such victories.

The win allowed Arizona to keep pace with the first-place Los Angeles Dodgers who lead the National League West by 5½ games.

Starting pitcher Pat Corbin labored through six innings but still managed to give up only two runs. Corbin walked three hit two batters and issued a wild pitch. The five free passes tied a season high.

“I was leaving some balls up over-rotating a little bit” Corbin said. “My mechanics were off a little bit on kind of everything. I didn’t really control my pitches too well today.”

Still Corbin was boosted into position for his first win since July 23 as Arizona broke a 2-2 tie in the bottom of the sixth on Wil Nieves’ two-run double off Mets starter Jeremy Hefner.

The Diamondbacks totaled seven hits including 10 that went for extra bases after Gibson decided to stick with the same batting order for the third game in a row only the second time he’s done that this season.

In those three games all wins Arizona has totaled 30 hits and 20 runs.

The versatility of Martin Prado has allowed Gibson to get all his most potent offensive parts in at once and Prado — normally an infielder — played left field for the third straight game so that Eric Chavez could man third base.

Gibson joked before the game that Prado was getting bored in left although that was quickly remedied in the second inning on one of two stellar defensive sequences the Diamondbacks put together.