BERLIN (AP) — A man fatally stabbed two people and wounded five others on a train in northern Germany on Wednesday before being arrested, police said.

German Federal Police said the man used a knife to attack several passengers shortly before a regional train traveling from Kiel to Hamburg arrived at Brokstedt station.

Police spokesman Juergen Henningsen said two of the people stabbed died after the attack.

Schleswig-Holstein state interior minister Sabine Suetterlin-Waack said the attack happened around 3pm local time.

«It’s terrible,» Suetterlin-Waack told German public broadcaster NDR. «We are shocked and horrified that something like this happened.»

Regional police and federal police were on the scene and the prosecutor’s office was investigating the attack, NDR reported.

The Brokstedt train station was closed for several hours.

Police did not provide any information on the suspect’s identity and said his possible motives were under investigation.