NEW YORK -- When New York Mets manager Terry Collins rose from the top step of the visiting dugout at Yankee Stadium and went to take out Dillon Gee, for a change, he was able to tell the struggling right-hander that he did a good job.
Actually, it was more than good. It was dominant.
Gee struck out a career-high 12 hitters in 7 1/3 innings and helped the Mets complete their first season sweep over the Yankees with a 3-1 victory Thursday night.
"Finally he told me, 'Good job,'" Gee said with a laugh. "He didn't say finally. He said, 'Good job for once,' but I'm just glad to be on that side where I help the team out."
Gee won for the first time since May 1 at Florida but produced much more dominating stuff than his previous victory. He allowed a solo home run to Robinson Cano in the third inning but was unhittable the rest of the game while showing more aggressiveness than in previous starts.
"He was determined the whole game," Mets catcher Anthony Recker said. "He was determined to prove something, and he did. He was awesome. Everything was locating, everything was down, and he was really good."
Gee retired the final 15 hitters he faced, getting nine of his strikeouts in that stretch. His most impressive run took place when he struck out Travis Hafner for the final out of the sixth, then fanned Lyle Overbay, Brennan Boesch and David Adams on 14 pitches in the seventh and Reid Brignac for the first out of the eighth.
"When you look up, he was throwing a lot of strikes," Yankees manager Joe Girardi said. "His changeup a lot of times looks like a strike. Guys were swinging, and they didn't hit it."
The third time through the Yankee lineup, Gee threw just 36 pitches. He entered the game allowing a .488 batting average when facing hitters for the third time in a game. That plagued him in his last loss, when he got the first two outs of the fifth against Atlanta before giving up five runs.
"That was my mindset," Gee said. "I went out in the sixth and seventh and (thought) this was my game. We're going to attack guys. That's the way I'm going to pitch, and I hadn't been doing it lately."
Gee produced his longest outing since July 7 against the Chicago Cubs. Thursday's strong performance occurred after Collins hinted that Gee might be moved to the bullpen if his struggles continued.
"I talked to Dillon the other day after his last start because he was sailing through and all of a sudden he hit a wall," Collins said "My question was, 'How are you feeling?' and he said, 'I'm disappointed in the fact that I haven't been able to be very consistent.'
"Then I asked if he was hurt, and if you're not hurt, it's got to be something else. There was some frustration, and he understood that. I said if a change is going to have to be made, I'm going to have to take you out of the rotation, and he said, 'I don't blame you.'"
Gee threw just 88 pitches before Collins pulled him.
Left-hander Scott Rice got the final two outs of the eighth, and Bobby Parnell retired the side in order in the ninth for his ninth save.
The Yankees lost their season-worst fifth game in a row, and they fell for the seventh time in the past nine games. They managed just four hits and wasted a decent outing from Vidal Nuno (1-2), who allowed a two-run home run to Marlon Byrd in the second among three hits in six innings.
"Unfortunately they just had a good couple of at-bats and they found a way to score runs," Nuno said.
John Buck's infield single in the eighth off Joba Chamberlain accounted for the other run for the Mets, who completed their fourth series sweep of the Yankees. Before this week, they had swept a three-game series at Shea Stadium in 2004 and a rain-shortened, two-game set at Yankee Stadium in 2008.
The Mets topped the Yankees on Monday and Tuesday on Citi Field before winning Wednesday and Thursday in the Bronx.
After wasting Justin Turner's leadoff double in the first, the Mets went up 2-0 on Byrd's two-run home run to left field in the second. It was Byrd's second home run in as many nights and sixth overall.
The Yankees halved the deficit in the third when Cano hit a 1-0 slider into the right field seats for his 14th home run.
NOTES: Mets SS Ruben Tejada was placed on the disabled list with a right quad strain, which is the same injury that cost him seven weeks last season. To take Tejada's place, the Mets selected the contract of INF Omar Quintanilla from Triple-A Las Vegas. ... The Mets said that LHP Jon Niese would miss his scheduled Saturday start in Miami due to left shoulder tendinitis. RHP Collin McHugh will start in Niese's place. ... Yankees 3B Kevin Youkilis (back) and 1B Mark Teixeira (forearm) each went 1-for-3 in their second rehab game for Double-A Trenton. Both could return Friday against the Boston Red Sox. ... Yankees LHP Andy Pettitte is expected to return from the DL for a Monday night start against the Cleveland Indians after missing two weeks with an upper back injury. ... The Yankees announced that they will honor 2009 World Series MVP Hideki Matsui in a pregame ceremony July 28 before they play the Tampa Bay Rays. That date was selected because Matsui wore No. 55 and it is the team's 55th home game of the season.