WASHINGTON (AP) — The GOP-controlled House voted Thursday to reject President Barack Obama’s policy to end deportation of hundreds of thousands of immigrants in the country illegally who were brought to the United States as children.

The 224-201 vote broke along party lines and comes as Congress is working on overhauling the much-criticized U.S. immigration system. The measure came as the House completed action on the Department of Homeland Security spending bill.

Obama announced a program in June 2012 that puts off deportation for many people brought here as children. Applicants for the reprieve must have arrived before they turned 16, be younger than 31 now, be high school graduates or in school, or have served in the military. They can’t have a serious criminal record.

One of the most widely-backed elements of immigration reform, known as the DREAM Act, would award these immigrants legal status.

Obama’s program, done by executive action, doesn’t give such immigrants legal status but it at least protects them from deportation for two years.

Amendment sponsor Steve King, R-Iowa, is a strident opponent of relaxing U.S. immigration law. He said any changes to U.S. policy should be enacted by Congress, not orchestrated by the president.

“Whatever people think of the impending immigration policy here in the United States, we cannot allow the executive branch to usurp the legislative authority of the United States Congress,” King said during debate Thursday night. “If we allow that to happen in immigration, it could happen to anything.”

Democrats opposed the measure and the addition of the amendment dampened Democratic support for the underlying spending bill. They said it’s not fair to deport people who were brought here as children. For many, America is the only country they know.

“We should not hold children responsible for the actions of adults and their parents. We should give them an opportunity,” said Rep. Luis Gutierrez, D-Ill.