AUBURN HILLS, Mich. — Georgia’s presidential hopefuls parried tough questions at Wednesday night’s debate, while their chances may have been bolstered by an “oops” moment from a key rival.

The layout said it all: Former Massachusetts Gov. Mitt Romney, the experienced and well-funded front-runner, in the middle, with Newt Gingrich to his right and Herman Cain to his left, positioning based on a recent national poll. The race has seen various candidates take turns holding the spot Cain has now as Romney’s top competitor, including Texas Gov. Rick Perry.

Perry has slipped because of poor debate performances, and had perhaps his worst flub Wednesday night when he could not remember all three government agencies he is planning to eliminate.

After a painful few seconds of searching, Perry said: “The third agency of government I would ... I would do away with, Education, the ... Commerce and, let’s see. I can’t. The third one, I can’t. Sorry. Oops.” He later recalled it was the Department of Energy.

Meanwhile, Stockbridge businessman Cain kept his typical sunny disposition and relentless promotion of his 9-9-9 tax plan in the face of a question about decade-old sexual harassment allegations that surfaced in the past two weeks.

And Gingrich, the former U.S. House Speaker from Georgia, kept up his attacks on the media and displays of policy knowledge, while fending off a question about earning hundreds of thousands in consulting fees from federally backed housing lender Freddie Mac.

The debate, on the campus of Oakland University, was hosted by CNBC and focused on economic issues. The moderators did dip a toe into the harassment allegations, with CNBC host Maria Bartiromo asking Cain if voters should ignore questions of “character” when it came to his campaign.

“The American people deserve better than someone being tried in the court of public opinion based on unfounded accusations,” Cain said. He added that for every one accuser “there are thousands who would say that none of that activity came from Herman Cain.”

He also pointed to his fundraising success of the past two weeks as the scandal has grown.

Cain’s campaign has been nearly overtaken by sexual harassment allegations by four women, two of whom have come forward publicly and two of whom received paid settlements from the National Restaurant Association, where Cain was CEO in the 1990s.

Cain has forcefully denied the allegations and said their emergence is part of a plot to sink his candidacy by the media or a political rival. Wednesday’s debate was the first since the allegations were reported, and Cain’s GOP rivals continued their trend of avoiding direct attacks on the subject.

Romney was asked whether, given the allegations, he would have kept Cain as CEO if he had acquired his firm during Romney’s venture capital days.

“Herman Cain is the person to respond to these questions, he did, and the people in this room and across the country can make their own assessment on that,” Romney said.

The people in the room booed the questions and applauded when the moderators returned to economics.

During a discussion of the housing market, CNBC’s John Harwood quizzed Gingrich about $300,000 in consulting fees he received from federally backed housing lender Freddie Mac, asking if he was trying to help them fend off regulation by the George W. Bush administration.

Gingrich said he never did any lobbying, only offered the company advice on their policies of pushing high-risk mortgages: “This is a bubble. This is insane. This is impossible,” Gingrich said he told Freddie Mac.

“It turned out, unfortunately, I was right,” he added.

The candidates did not directly confront each other, leaving the sparring for the moderators. Gingrich again said the format was inadequate to address important policy issues and mentioned that he wanted to hold seven untimed Lincoln-Douglas style debates with President Barack Obama during the general election campaign.

He held one with Cain in Texas last weekend. A growing number of analysts see Gingrich as the candidate best positioned to take over Cain’s momentum if the former Godfather’s Pizza CEO’s campaign falters.

On the foreclosure crisis — potent in the Detroit area where the debate took place as well as in Atlanta – Gingrich proposed an immediate repeal of the Dodd-Frank financial regulation law, which he said punishes small banks. He also backed changing laws to make it easier to do a short sale, a sale of a home for less than it’s worth, than a foreclosure.

Romney pronounced those suggestions  “excellent ideas.”

All the candidates agreed that a stronger economy, accomplished by lowering taxes and reducing regulation,  would solve the housing market and most everything else. The ethos was summed up by Romney’s proclamation that, “Markets work. When you have government play its heavy hand, markets blow up and people get hurt.”

Romney stuck to that line through being quizzed on his apparently shifting position on the bailout of the automobile industry. Autos are the lifeblood of Michigan and, given the industry’s recovery, the Obama administration is touting the rescue of General Motors and Chrysler as a success story. Romney said the industry would have recovered even better through a managed bankruptcy that did not involve a federal bailout.

The other participants in the debate included Rep. Ron Paul of Texas, who showed up with his usual complement of chanting libertarian fans, Rep. Michele Bachmann of Minnesota, former Pennsylvania Sen. Rick Santorum and former Utah Gov. John Huntsman.