VIDEO: Israeli student stabbed in synagogue

The 22-year-old student is in stable condition at a Brooklyn hospital.

The knife-wielding man was fatally shot by police on scene.

An Israeli student was stabbed in the neck in an anti-Semitic attack while praying in a Brooklyn synagogue early Tuesday morning.

Levi Rosenblat, 22, was inside Chabad-Lubavitch—the Brooklyn headquarters of an international Jewish organization—when Calvin Peters, 49, entered the building around 1:40 a.m. yelling "kill the Jew" and stabbed the student in the neck, according to ABC News.

Others were in the synagogue when the incident occurred, but fortunately no one else was hurt. Those on scene managed to flag down a nearby patrol officer to stop Peters.

Peters, who initially complied with NYPD orders to put down the weapon, retrieved the knife and began approaching the officers, who then shot him in the stomach. He died at Kings County Hospital around 3 a.m.

Officials have confirmed that Rosenblat is in stable condition at a local hospital.

"I'm told that the attacker came earlier that evening, too. He was stalking the scene. Thank God he didn't inflict more harm nor do more damage to more people," Assemblyman Dov Hikind (D) wrote in an email statement to ABC News.

Hikind says officials are unsure what might have motivated the attack.

"We commend the heroic efforts of the individuals who were present and took immediate action. If not for their intervention the outcome could have been, God forbid far worse," said Rabbi Chaim Landa.

"While we are very pained by everything that has unfolded, we are very grateful to the police for their quick response and are working closely with the authorities in their ongoing investigation.”

NYPD say Peters had a criminal history.

Follow the author of this article on Twitter: @MaggieLitCRO