A bill that would allow school districts to arm teachers and other personnel with guns was approved Tuesday by the South Dakota House after supporters said it could make would-be attackers think twice about entering a school building.

Representatives voted 42-17 to send the measure to the Senate for further debate.

Supporters said school boards, particularly in rural areas where no law enforcement officers are stationed in school buildings, need the option of arming teachers, administrators or volunteers to protect against attacks like last month's school shooting in Connecticut. Opponents countered that arming teachers could make schools more dangerous because it could lead to accidental shootings and put guns in the hands of people who are trained to teach, not shoot people.

The bill's main sponsor, Rep. Scott Craig, R-Rapid City, said the measure leaves it up to each school board to decide whether to train and arm teachers and others. Schools are now inviting targets for potential mass murderers because they are considered gun-free zones, he said.

"The possibility of an armed presence in any of our schools is a deterrent," Craig said.

Rep. Ray Ring, D-Vermillion, said he opposes arming school personnel because it's more likely to lead to accidental shootings than to stopping attackers. He noted that associations representing local school boards, school administrators and teachers oppose the bill.

"Educators believe arming teachers and volunteers with minimal training will erode the learning environment without significantly improving security," Ring said.

Supporters argued the bill would require that anyone taking part in a so-called School Sentinel program complete training that would be designed by the same commission that sets training standards for law enforcement officers. Local law enforcement agencies also would have to approve such a program, and school employees could not be forced to take part.

Rep. Steve Hickey, R-Sioux Falls, said arming school personnel in some districts is only part of an overall approach to school safety. Some schools need to make their entrances more secure, and more mental health counseling is needed for students, he said.

Rep. Troy Heinert, D-Mission, said he doesn't want his son in kindergarten to think about his teacher being armed.

"Doesn't this bill blur the line between a teacher and a law enforcement officer?" Heinert said. "Do we want to tell our children the only way to be safe is to carry a gun?"

Rep. Stace Nelson, R-Fulton, said educators are trusted to teach students, so they also can be trusted to protect students from harm. Nelson, a retired law enforcement officer, said teachers can be trained to handle guns safely and effectively.