John Williams launched the attack in a McDonald’s restaurant, in Milton Street, Nottingham, on 9 December 2023.
Police were able to identify Williams as the attacker having attended previous incidents where he had been involved.
It is believed the two men had been involved in an earlier disagreement.
The victim required hospital treatment after suffering a large cut to his head which needed seven stitches.
Williams, aged 45, of no fixed abode, was jailed for a total of 18 months when he appeared at Nottingham Crown Court for sentencing on Thursday (30 May).
He had earlier pleaded guilty to inflicting grievous bodily harm without intent and breaching his bail conditions.