Tā yǐ zhèngshì de 「rì'ān」 dàitì le guàncháng de wènhòu.
He substituted the usual greeting with the formal 'good day'.
Tips
register
日安 is a formal or literary greeting calqued from the French 'bonjour' or classical usage. It is more often found in written Chinese, formal speeches, or translated texts than in everyday conversation.