The 2020 Democratic presidential hopefuls were asked about their views on decriminalizing illegal border crossings during the party's Thursday debate, and all but two candidates raised their hands.

Moderator Jose Diaz-Balart asked which candidates think illegal entry into the U.S. should be classified as a civil offense instead of a crime, and all but Sen. Michael Bennet, D-Colo., and former Colorado Gov. John Hickenlooper raised their hands.

ANDREW YANG'S NO-TIE LOOK SPARKS SOCIAL MEDIA FRENZY DURING DEMOCRATIC DEBATE

South Bend, Ind., Mayor Pete Buttigieg spoke first and said the idea of having sovereign borders was driving illegal immigrant families apart, and accused Republicans of using religion to mask their true intentions.

"Let's remember that's not just a theoretical exercise -- that criminalization -- that is the basis for family separation," Buttigieg said. "You do away with that, it's no longer possible. Of course, it wouldn't be possible anyway in my presidency because it's dead wrong. ... The Republican Party likes to cloak itself in the language of religion. Now, our party doesn't talk about that as much largely for a very good reason -- which is, we are committed to the separation of church and state and we stand for people for any religion and people of no religion, but we should call out hypocrisy when we see it."

Joe Biden spoke next and dodged the main question of decriminalization in favor of listing his accomplishments on immigration during the Obama administration.

"The first thing I would do is unite families -- I'd surge immediately, billions of dollars worth of help to the region immediately," he replied.

"Look, I talk about foreign policy. I'm the guy that got a bipartisan agreement at the very end of the campaign, at the very end of our term, to spend $740 million to deal with the problem. And that was to go to the root cause of why people were leaving in the first place. It was working."

Diaz-Balart followed up with Biden and pointed out how the Obama administration deported millions of illegal immigrants and asked the former vice president if crossing the border illegally should qualify as a deportable offense.

DE BLASIO APOLOGIZES FOR INVOKING CHE GUEVARA IN MIAMI, ADMITS TO NOT KNOWING THE HISTORY

"Depending if they committed a major crime, they should be deported," Biden said. "President Obama, I think, did a heck of a job. To compare him to what [Trump] is doing is absolutely -- I find ... immoral. But the fact is that look, we should not be locking people up. We should make sure we change the circumstance as we did -- why they would leave in the first place. And those who come seeking asylum, we should immediately have the capacity to absorb them [and] keep them safe until they can be heard."

Biden finally gave a clear answer after a second followup and said border crossers who have committed no other major offense shouldn't be targeted by the federal government.

Sen. Bernie Sanders, I-Vt., said he agreed with Kamala Harris on immigration and threatened to rescind almost every immigration policy enacted by the Trump administration, via executive order. He also suggested hosting a summit with Central American and Mexican leadership to find out why citizens are fleeing their countries in droves.

CLICK HERE FOR THE FOX NEWS APP

"We've got to look at the root causes. And you have a situation where Honduras among other things is a failing state -- massive corruption. You've got gangs who are telling families that if a 10-year-old does not join that gang, that family is going to be killed," Sanders said. "What we have got to do on day one, is invite the presidents and the leadership of Central America and Mexico together. This is a hemispheric problem."

Harris also was allotted time to speak on the issue and agreed with the previous candidates and said someone who crosses the border illegally should not be deported.