"Championship teams have to win some games like this," Mets second baseman Jose Valentin said. "Sometimes you're going to face a team like today that's playing great baseball. You're going to face a top pitcher like Webb."
Webb and New York's Martinez were as good as advertised, combining to throw 15 scoreless innings. Chavez came through with the big hit against Jason Grimsley (1-2).
Valentin led off the 13th with a double and advanced to third on Ramon Castro's groundout. Chavez then hit a 1-0 pitch into the gap in right-center to end it.
"I just focused (on) a pitch that I can drive to the outfield," said Chavez, who is listed as 6-foot, 165 pounds, "because they were playing in."
Duaner Sanchez (3-0) tossed three scoreless innings for NL East-leading New York, which took two of three in the series.
"It took someone like Pedro to have a game like that against Webb," Arizona manager Bob Melvin said. "You have to tip your hat to them. They pitched well."
Webb is unbeaten this season and was trying to become the majors' first nine-game winner. He tossed seven shutout innings to run his scoreless streak to 25, longest in the big leagues this year. He allowed four hits, struck out five and walked one.
Webb, coming off consecutive shutouts against Atlanta and Cincinnati, lowered his NL-leading ERA to 2.01.
"It was fun. We both pitched well which is, again, what I expected," Webb said. "We're going out there facing the hitters and not each other."
Martinez, a three-time Cy Young Award winner, matched Webb's effort by giving up five hits in eight shutout innings. The right-hander, who has allowed two earned runs in 24 innings, fanned eight and didn't walk a batter.
Martinez has five no-decisions and a loss in his last six starts despite throwing at least six innings in each outing. He went winless in May, the first month in which he has made at least five starts and failed to get a victory, according to the Elias Sports Bureau.
"I know I'm going to win a lot more games," Martinez said.
Highly touted Mets prospect Lastings Milledge had an eventful night in right field in his second major league game. He dropped Johnny Estrada's flyball in the second, but threw out Craig Counsell trying to take third on Chad Tracy's single in the sixth.
Milledge's perfect throw prevented the Diamondbacks from putting runners on the corners with one out.
"It was an aggressive play, I'd probably do the same thing," Milledge said. "I knew I had him as soon as I let it go. Everything went smoothly and perfect. I had to pick it clean and I had to throw it on point."
Martinez started slowly but quickly picked up the pace. Eric Byrnes singled in the first inning and stole second but Martinez struck out Tracy and induced Luis Gonzalez to pop out to end the inning.
Estrada reached on Milledge's two-out error in the second, and Orlando Hudson followed with a single. Webb then hit a grounder up the middle that second baseman Valentin stopped with a dive before flipping to second for the inning-ending forceout.
Martinez set down Arizona in order in the next three innings, striking out two in the third and fifth.
Webb also cruised along, holding the Mets in check with his tough sinker. Carlos Delgado hit a long flyball in the second but Byrnes jumped against the wall in center field to make the catch.
"He's got a great sinker," Mets manager Willie Randolph said. "He threw a lot of sliders. He made adjustments. We couldn't figure him out."
Webb retired 11 in a row before David Wright singled with two outs in the seventh. Wright advanced to third on a single by Cliff Floyd, who then stole second. But Webb retired Valentin on a popout.
"I didn't know if I was coming out that inning or may go after one more but that was a pretty big out, with guys on second and third getting him to pop out," Webb said.
Mets center fielder Carlos Beltran fouled a pitch off the inside of his right knee in the 11th and went to the ground in the grass behind home plate. Beltran continued his at-bat after a trainer and Randolph came out to check on him. He struck out with a runner on second and was replaced in the field.
X-rays were negative and Beltran is day to day with a bruised knee.
- Webb made his 108th career start for Arizona to move ahead of Curt Schilling for third most in franchise history. Randy Johnson (192) and Brian Anderson (129) are the only two players with more.
- Byrnes' first-inning single extended his hitting streak to a team-high 14 games.
- OF Xavier Nady was released from the hospital Wednesday after an appendectomy Tuesday. The Mets placed Nady on the 15-day DL Tuesday.
- Chavez replaced Milledge in the 11th.