Investigators were racing Saturday to pinpoint the motive of a man who went on a knife rampage in the German city of Wuerzburg, killing three people and leaving five seriously injured. The suspect, a 24-year-old Somali who arrived in Wuerzburg in 2015, staged the attack in the city centre on Friday evening, striking at a household goods store before advancing to a bank. He was later overpowered by police after they shot him in the thigh. Investigators found records showing that the man had been treated at a psychiatric institution, and police said he was not a known Islamist. Chancellor Angela Merkel said the investigations will show what drove the man to go on his rampage. “But what is certain is that the horrific act is directed at all humanity and every religion,” her spokesman Steffen Seibert tweeted. But the far-right AfD party immediately seized on the violence that has erupted just three months before general elections. The anti-immigration party’s co-leader Joerg Meuthen noted that a witness had reportedly heard the suspect shouting “Allah Akbar” (God is greatest). Meuthen lamented the latest “Islamist knife murders in the middle of Germany,” adding that it was a “tragedy for the victims, who have my sympathy and another manifestation of Merkel’s failed migration policy”. The AfD has railed that Merkel’s decision to allow in more than one million asylum-seekers — many fleeing Iraq and Syria — since 2015 has contributed to a heightened security risk. Spiegel Online reported the suspect had said in an interrogation that the act was his “jihad”. If confirmed as an Islamist act, the case risks reopening a bitter debate in Germany over immigration — a topic that has taken a backseat so far in this year’s election campaign, compared to the last polls in 2017 when the AfD won seats in parliament for the first time. ‘Sad and shocked’ In the Bavarian city, residents brought flowers and candles in the morning to the scene of the stabbing. “I’m extremely sad and shocked and that’s why I’m here. I find that’s the least one can do — show sympathy,” said Wuerzburg resident Franziska brought candles with a friend. Others were asking police officers stationed at the site what had happened, an AFP reporter witnessed. President Frank-Walter Steinmeier voiced shock at the “extreme brutality” of the crime.