Police were called to an address on Old Hall Drive, where they found Mark Hercock unsteady on his feet and apparently drunk, carrying a Stanley knife, at 3pm, on June 24.
Emma Cornell, mitigating, said Hercock, of previous good character, had been working at an antiques fair and forgot he had the knife in his pocket.
She said: "He has been an alcoholic for 15 years and he relapsed into drinking after his relationship of 14 years broke down.
"He can't remember an ambulance being called and he is currently on medication. He has been dry for ten days."
Probation officer Raqia Bano said he was looking for sympathy and that was why he said what he said, but he could not recall the incident.
Hercock, 38, of Moorgate, admitted possessing the blade, when he appeared at Mansfield Magistrates Court, on Friday.
He received a 12 month community order with 20 rehabilitation days and a six month alcohol treatment requirement.
He was fined £93, with £85 costs and an £85 government surcharge.
For more of the latest court cases click here.