A teenager wounded three teachers and one pupil in a stabbing in a high school in Jerez de la Frontera, southern Spain, police said.
One of the teachers will undergo surgery, while the other three victims suffered light wounds, a source from Andalusia's health services said.
Police said the attacker had been detained. Canal SUR television channel showed parents congregating outside the school gates.
A pupil's mother told the station the attacker had wielded two large knives from his backpack inside a classroom and attacked fellow pupils and teachers at about 8:15 a.m. (0615 GMT) local time, telling them he would kill them.