Conor Jackson's was terrible, Ryan Church's terrific.
The first baseman Jackson's ninth inning throwing error allowed Carlos Beltran to score the Mets' go-ahead run from second.
"The ball just got away from me," said Jackson, praised by Arizona manager Bob Melvin for his improved defensive play this year. "I made a bad throw."
Moments earlier, in the eighth, Chris Burke laid down a bunt and pitcher Pedro Feliciano threw wildly past first base. Burked raced to second, then was waved to third by third base coach Chip Hale.
Meanwhile, the right fielder Church chased down the ball and threw perfectly to third, where David Wright tagged Burke out.
"The biggest thing was just getting the grip of it and letting it go, basically chuck it," Church said. "David did a great job of deking the runner a little bit, just grabbed it and snapped tag."
Melvin defended Hale's decision.
"Sometimes there's judgment involved and it just didn't work out," Melvin said.
Burke obviously wished he would have stayed at second.
"It was fortunate and unfortunate all in one play," he said, "just a frustrating play for the team because it could have set us up to take the lead, and then you never know what happens from there."
The Mets won at Arizona for the 15th time in 17 tries and handed the Diamondbacks' just their second series loss of the season. The only other series Arizona lost was its season-opening three-game set at Cincinnati.
Wright had a solo home run for the Mets.
With the score tied at 2 in the ninth, Beltran and Moises Alou singled off reliever Chad Qualls. Carlos Delgado grounded to Jackson, who overthrew shortstop Augie Ojeda to allow Beltran to score.
"Any time a team makes mistakes on you, you make sure you make them pay for it," New York manager Willie Randolph said. "It was kind of a weird game. A few crazy things happened out there, but we scored early and late and got the job done."
New York went on to load the bases and get an RBI single by pinch hitter Marlon Anderson and an RBI sacrifice fly by Jose Reyes.
Qualls (0-2) gave up three runs, one earned, in one inning. Jorge Sosa (4-1) pitched 2/3 of an inning to get the victory. Billy Wagner threw a perfect ninth for his seventh save in eight tries.
Arizona's Mark Reynolds broke out of a 1-for-21 slump with a pair of bloop singles, the second bringing home the tying run in the seventh.
Johan Santana and Dan Haren, a pair of transplanted American League standouts, dueled through six innings, with the Mets leading 2-1 on Wright's leadoff home run in the fourth.
Joe Smith relieved Santana and got two quick outs in the seventh, but Jackson singled, then Justin Upton walked.
Reynolds blooped a broken-bat single to left to bring home Jackson and tie it a 2-2.
Santana allowed a run and six hits, striking out eight and walking four. Haren allowed two runs and only three hits. He struck out seven and walked one.
Reyes' two-out single, the first hit off Haren of the game, brought home Luis Castillo to put the Mets up 1-0 in the third.
New York made it 2-0 when Wright, leading off the fourth, hit Haren's 2-0 pitch deep into the left field seats, his sixth homer and 26th RBI of the season.
Arizona broke through with a run in the fourth. Upton singled, then scored when Chris Snyder lined one off the top of the bullpen fence in left, just inches shy of a home run, for his first career triple.
"Only the second series we've lost and it came right down to the ninth inning," Haren said. "You know, they're a good ball club, the Mets. I'm sure they'll be there at the end. I'm sure we'll be there at the end. We played them tough. They played us tough. This game could have gone either way."