President Trump on Friday demanded that Democrats approve funding for his signature Mexican border wall before he supports a program designed to protect immigrants brought into the US illegally as minors.

“The Democrats have been told, and fully understand, that there can be no DACA without the desperately needed WALL at the Southern Border and an END to the horrible Chain Migration & ridiculous Lottery System of Immigration etc.,” he said in a morning tweet.

“We must protect our Country at all cost!”

DACA refers to the Deferred Action for Childhood Arrivals program, which protected almost 800,000 youngsters — known as “Dreamers” — brought into the US illegally by their parents.

In September, the Trump administration announced it would end the Obama-era program after March 1 unless Congress finalizes a deal on the issue and approves new border enforcement measures.

Republicans and Democrats have been trying to find a legislative solution to prevent the Dreamers from being deported, but lawmakers left town without including a DACA deal in a short-term government funding measure, which expires on Jan. 19.

Left-leaning groups like Credo Mobile and Democracy For America have slammed House Minority Leader Nancy Pelosi and Senate Minority Leader Charles Schumer for not securing the provision to protect Dreamers in the spending bill.

“For months, Democratic leaders insisted they would use their leverage in year-end spending bill negotiations to protect Dreamers and reauthorize the Children’s Health Insurance Program, but at the end of the day they let us down and refused to even put up a fight,” CREDO political director Murshed Zaheed said in a statement, according to The Hill.

In attacking the “Diversity Visa Lottery Program” and “chain migration,” Trump was reiterating his call for the two immigration programs to come to an end.

“Chain migration” gives preference to individuals who are related to immigrants who are already in the US legally. Trump favors scrapping the lottery visa system in favor of a merit-based admission process to the US.

Last month, Trump lashed out at Schumer and the lottery visa program that a terrorist who plowed into pedestrians in Lower Manhattan reportedly used to enter the country.

“The terrorist came into our country through what is called the ‘Diversity Visa Lottery Program,’ a Chuck Schumer beauty. I want merit based,” Trump said in a tweet.