San Diego had lost all of its previous three games this season that went extra innings. The Padres played extra innings for the third time in five home games, including a 22-inning loss to Colorado on April 17 that lasted 6 hours, 16 minutes. This one went 4:02.
"It was a great win against a very hot team," Padres manager Bud Black said. "Every pitch from the seventh inning on was critical. If there is a silver lining, when we play these games, we feel comfortable."
San Diego had also lost at San Francisco on April 8 in an 11-inning game that went 3:24, and a 13-inning affair against the Giants that lasted 3:51 on Wednesday.
Iguchi's homer came on a full-count pitch from Petit (0-1), and was Iguchi's first home run since Aug. 27, when he played for Philadelphia. The home run was also San Diego's first hit since the sixth inning as it won for just second time in 11 games.
"I didn't really expect to hit one there," said Iguchi through a translator.
"It's just human nature to try and be the hero and end it," Diamondbacks manager Bob Melvin said. "It looked like that was the case with both sides, and they finally got one out."
Arizona lost for only the third time in 11 games.
Iguchi's homer was his first walk-off shot since he came to the majors in 2005 with the Chicago White Sox.
"We are struggling as a team," he said. "To be able to hit one there was big."
Glendon Rusch (1-2) allowed two hits in four innings with four strikeouts and two walks.
The Padres had leads of 4-0 and 5-2 before Arizona scored in the fifth on a two-run triple by Orlando Hudson and added two more runs in the sixth, including an RBI double by pitcher Micah Owns, for a 6-5 lead.
San Diego went ahead 7-6 in the bottom half on Adrian Gonzalez's two-run single. Arizona tied it in the seventh after a leadoff double by Eric Byrnes, who was sacrificed to third and scored on Conor Jackson's single.
Gonzalez drove in three runs for the Padres, who came into the game second to last in the majors in runs scored. San Diego had scored just six runs in the previous 63 innings at spacious Petco Park before it pushed across four runs in the second inning off Owings.
"We know we are a better team offensively than what we've shown," Gonzalez said. "Hopefully, this is a sign of things to come."
Brian Giles hit a solo homer, his second, in the fourth off Owings for a 5-2 lead. It was San Diego's first home run at home in nine games since Giles connected on April 4 against the Los Angeles Dodgers, a span of 378 plate appearances and 93 innings.
Chris Young hit a two-run homer for Arizona, which has the best record in the majors at 17-7.
Owings left the game with a sprained ankle in the sixth inning after his RBI double down the right-field line. He pulled up into second base when his right leg buckled as he stepped on the base. Owings fell off the bag before he retouched the base and called time.
Owings sat on the infield dirt for a couple of minutes before he limped off the field.
"I just slowed up and stepped on the bag and kind of rolled off the back end," Owings said. "It feels stiff, but I'm not too worried about it."
The right-hander allowed five runs on five hits in five innings with five strikeouts and three walks. Owings had three hits and scored twice.
San Diego took a 4-0 lead in the second with the help of three walks by Owings. Starting pitcher Justin Germano had an RBI single followed by a two-run single by Paul McAnulty before Gonzalez followed with an RBI single.
The Padres had lost six straight extra-innings games, dating to last season. Their last win in extra innings was Aug. 23 at the New York Mets. ... Diamondbacks right fielder Justin Upton left the game in the seventh inning with a cramp in his left hamstring. ... San Diego's Jake Peavy received his 2007 Cy Young Award in a pregame ceremony. Peavy, Sunday's scheduled starter, also received the Players Choice Award for Outstanding NL pitcher of the year. ... Arizona catcher Chris Snyder was a late scratch from the lineup with the flu.