13 pages on a guy that made an unfunny joke ...
Some of us remember very clearly being the child who was confused and wrongfooted by an unfunny joke, especially if we have anxieties which lasted into adulthood. That is probably why some of us feel very strongly about things like this. And as someone who has volunteered with autistic people, it's one of many things which makes the world all the more difficult for them to live in.
Being on the receiving end of these is one reason of many that I hated being a child: I can remember the feeling of confusion and panic as if it was yesterday, and when you thought you were in control, and suddenly it all comes crashing down. It's especially bad if it's done in a deadpan, totally serious voice, as might be used by an angry adult telling you off. It's harder for a young child to tell the difference.
Can't believe some people are saying low level bullying etc.
I can. "Jokes" like this can be a step towards bullying. I wouldn't be surprised if some school bullies pick their victims by doing this to see who reacts most, and therefore who will give them most laughs later.
Certainly the OP's incident was unwanted teasing, but in spite of what I said above, I wouldn't call this bullying - yet. If the shopkeeper then mentioned it every time he saw the OP's child (which I've had done to me - some bit of teasing I didn't like mentioned again and again), that would be bullying in my book.
I do think that people making jokes like this to children is one thing that makes bullying thrive; it normalises the idea of having a laugh at someone's expense, and picking on a weak target (a child). The children who do like receiving such jokes will then do them on their peers more, including the ones who don't like being teased. And then the children who don't like it will then feel resentful about it, and might start looking for a chance to hit back. As they can't hit back at the adult who made the joke, they're more likely then to pick on someone their own age.
As for the shopkeepers who have done it to adults: well, adults will vote with their wallets. Word gets around. Shopkeepers and sales staff: do it at your peril, see yourself or your shop mentioned by name on Twitter. It also makes it harder for other people who work in retail; see the many other threads on what a shitty job retail can be. And the ticket inspector that was mentioned earlier: I'd have reported him to the ends of the Earth; the fact that he was in a position of a lot of authority makes it far worse.
Now a completely different example of confusing a child over jokes like this: I remember a few months ago a thread where an entertainer said to a child delighted to be invited up on the stage "your feet smell". The child, playing along, replied "so do yours". One of the child's parents then intervened and punished said child for being "rude".
No wonder children get confused.