
People often complain about being 'ordered' to have a nice day by shop assistants or coffee shop workers or pretty much anyone American.
I'm no grammar nazi but here's the thing. 'Have a nice day' is not an imperative, an order. It's a subjunctive, expressing a hope or wish (it also has other uses).
Other examples of this use of the subjunctive are:
Get well soon
Long Live the King
Live long and prosper
Goodbye (god be with ye)
Farewell
Hallowed be thy name
(Have a) Happy Birthday
(Have a) Happy Christmas
The old English 'Wassail', a contraction of 'Waes Hail' means 'be healthy', a kind of early version of 'have a nice day'. If/when the NHS falls apart we might want to revive it.
It's harder to spot a subjunctive in English because there is no special verb form to indicate it as there is in other languages. In French, for example, 'hallowed be thy name' is 'que ton nom soit sanctifié' and the soit gives it away.
This may not make it any less annoying the next time someone says 'have a nice day' and you know they don't give a toss but at least now you can be annoyed for the right reasons.