Derek Handley, 50, Marina Close, Lostock Hall, had been sacked from his job at Network Rail after an altercation with a parking attendant, and appeared to blame his former colleague, Preston's Sessions House Court heard.
Prosecuting, Bob Sastry described how the terrified mum had called police at around 3.45pm on December 14 after Handley entered a woman's home on Welbeck Crescent, Bamber Bridge looking for her partner - who was not living there at that time.
He said: " She was at home with her four year old daughter in the lounge when she heard someone shout 'hello'.
M6 reopens after vehicle transporting sheep overturns following crash between Preston and Lancaster
The Old Vicarage Care Home: special measures status for Lancashire care home where resident was left lying on floor after falling out of bed
Lytham St Annes care home boss appears in court after death of residents
Preston Brick Veil Mosque inquiry closes as debate rages over whether the place of worship should be permitted
M65 motorway crews strimming verges until 4am keep residents awake at night
"The defendant walked up the stairs and she realised it was the def - she recognised him because he was a former colleague and friend of her partner.
" Mr Handley was wearing a grey dressing gown and was clearly intoxicated, and as he was walking up the stairs. He produced a small knife.
"He said he had ruined his life and he wanted to talk to him."
"Mr Handley did show the knife to her but made no threats towards her, but of course because her four-year-old daughter was present she was greatly concerned."
The mum asked him to leave and threatened to call the police.
When she looked outside she could see him standing by his black Jaguar car and could see a bottle of wine placed on top of it.
Police found the car unlocked, with the keys in, close to her home, with the small knife on one of the seats.
Handley, who has 12 convictions for 19 offences, admitted affray, possessing a sharply pointed article and drink driving.
Defending Richard English described him as a "good, kind man" who had had a fairly torrid time, and had become alcoholic.
He added: " She makes clear there was no direct threat. The circumstances were frightening but there was no direct threat. This is an unusual case.
"He was drunk, he was angry and he blamed him for losing his job, quite unfairly he realises.
"He has worked all his adult life until he was dismissed from the job he loved.
"Not a day has gone by when he doesn't want to apologise to the woman he frightened."
Recorder Neville Biddle imposed four months in jail, suspended for two years, with a rehabilitation requirement and alcohol treatment requirement
He was banned from driving for two years.
The Lancashire Post is more reliant than ever on you taking out a digital subscription to support our journalism. For unlimited access to Lancashire news and information online, you can subscribe here.