MIAMI (AP) -- The punchless Miami Marlins have become last-inning dynamos.
Juan Pierre scored standing up on a wild pitch with none out in the ninth, and Miami came from behind in the final inning for the second consecutive game to beat the reeling New York Mets 2-1 Tuesday night.
Miami, last in the majors in runs and last in the NL in wins, had a little help with its latest comeback. A passed ball and disputed call in the ninth preceded the wild pitch.
''It was just a weird ending,'' Pierre said. ''We're trying to find ways to win. We found all the ways to lose. Now we're trying to get on the winning side.''
The Mets have lost a season-worst six games in a row. They were beaten Monday when Miami scored twice in the 15th inning to win 4-3.
The Marlins earned consecutive walk-off wins for the first time since July 22-23, 2010.
New York's Jeremy Hefner (0-3) took a 1-0 lead and a three-hitter into the ninth but couldn't get another out.
Chris Coghlan singled to start the inning and advanced on a passed ball. When Pierre bunted, Coghlan beat catcher Anthony Recker's throw to third, although the Mets argued that Coghlan overslid the bag.
''It looked close,'' Marlins manager Mike Redmond said. ''If he was out, then it was a break for us. We've been talking about needing a break. If that was it, then it was a big break for us.''
Brandon Lyon replaced Hefner, and Donovan Solano hit an RBI single to right that sent Pierre to third. An intentional walk loaded the bases, and Lyon's first pitch to Greg Dobbs was a low breaking ball that got away from Recker, allowing Pierre to score.
That gave the Marlins a season-high three-game winning streak, and spoiled Hefner's best outing of the year. He had a career-high eight strikeouts and lowered his ERA from 5.14 to 3.72.
''That guy was manhandling us for eight innings,'' Pierre said. ''Again we did nothing offensively tonight, but we didn't give in.''
Miami, which ranks last in the majors in batting average and homers, didn't advance a runner beyond first base until the ninth against Hefner.
''He pitched an absolutely brilliant ballgame,'' Mets manager Terry Collins said.
Hard-luck Kevin Slowey remained winless since 2010 despite allowing only one run in eight innings to lower his ERA to 2.15. The Marlins have scored eight runs in his six starts, the worst run support for any NL pitcher, but he said his only concern was that the Marlins won.
''Games like Monday night and today bring a team together pretty quickly,'' Slowey said. ''You grow together. When you have a few victories that are hard-fought and well-earned, it's a great feeling.''
The only Mets run scored on Recker's sacrifice fly in the fifth. They totaled four hits and went 0 for 3 with runners in scoring position after going 1 for 18 in those situations Monday, and New York fell to 1-6 in one-run games.
''Everybody's struggling,'' Collins said. ''We have to fight through it.''
Ryan Webb (1-1) pitched a perfect ninth.
The Marlins were without slugger Giancarlo Stanton, who went on the disabled list Tuesday with a strained right hamstring and expects to be sidelined for about a month. Marcell Ozuna was called up from Double-A Jacksonville to replace Stanton and went 1 for 3 in his major league debut.
David Wright returned to the Mets lineup after missing one start with a stiff neck and went 0 for 4.
Hefner's most awkward moment came in the sixth, when he had to scramble after a grounder hit by Pierre. The ball hit off Hefner's glove and chest and rolled toward first. The pitcher picked it up on the run and tossed it for the out but then skidded across the infield dirt on one knee as teammates laughed.
New York's Daniel Murphy doubled to start the fifth, went to third on a flyout and scored the game's first run on Recker's sac fly.
NOTES: The Mets' John Buck was given the night off after catching all 15 innings Monday. With nine home runs, Buck tied the major league record for most homers by a catcher at the end of April, held by Johnny Bench (1971 Reds) and Charles Johnson (2001 Marlins), said the Mets, citing information from the Elias Sports Bureau. ... Slowey became the first Miami pitcher this season to throw more than seven innings. The outing was his longest since July 31, 2010. ... Recker was warming up to pitch the 16th inning Monday for New York when the Marlins won the game in the 15th. The Mets were out of relievers, and Recker pitched several games in college.