If a speech is of a nature of wish, blessing or any other suitable verb, the exclamation sentence is changed in a statement during converting it to indirect speech. The exclamation sign is omitted.
The sentence in indirect speech becomes- He wished them for doing well in exams.