A homeless man chased children through a town centre with a knife after they threw stones at him.
Police were called to Market Place in Dewsbury by a member of the public who witnessed the frightening episode on Tuesday afternoon.
Drunk Csaba Balazs claimed that he only got the knife, which had an eight-inch blade, out to scare the youngsters after they “bombarded” him and two other rough sleepers with stones.
The 53-year-old, originally from Hungary, appeared at Kirklees Magistrates’ Court and pleaded guilty to unlawful possession of an offensive weapon in public.
He was jailed for six months by District Judge Michael Fanning who told him: “Knife crime breeds knife crime.
“If children see you threatening them with a knife their learnt response is to carry knives.”
Prosecutor Alex Bozman said that police responded to the incident at 1.30pm.
He explained: “A member of the public said that there was a man in the town centre chasing children with a knife. Balazs was detained and a silver metal knife was found in his left pocket.
“He said he didn’t have the knife initially but when one of the boys stopped and gestured he got it out.
“The purpose of it, he said, was to be left alone.”
Balazs, who admitted that he had a drinking problem, said that he normally used the knife for eating and for his casual work as a painter and decorator.
Erica Topham, mitigating, said that her client was part of a group of three who slept rough in the park in the town.
She said: “It’s the same youths who come into the place where they are sleeping and bombard them with stones all the time.
“His temper broke and he ran after them.
“He’s adamant that he didn’t have a knife until the lads turned round and started beckoning him to come at them more.
“It’s then that he got the knife out of his pocket and showed it to the children to frighten them.”
Judge Fanning told Balazs that, although he had no previous convictions, he had to know that knife crime in the UK was “going through the roof.”
He said: “People are willing to use knives on the streets of Britain to injure and kill.
“You lost your temper and brandished the knife intending to cause fear.
“I can’t for a moment understand why anybody would find it amusing to stone somebody who is homeless on the streets.
“But the message has to be sent that nobody brandishes knives and uses them.
“I sympathize with your position but I have to send you to prison for 24 weeks.”