Al-Adab Al-Mufrad, Book 33, Hadith 41 (In-Book) ⓘ
Abu Hurayra reported that the Messenger of Allah, may Allah bless him and grant him peace, said, "When one of you wishes for something, he should look to what he desires. He does not know what he will be given."
حَدَّثَنَا مُسَدَّدٌ، قَالَ: حَدَّثَنَا أَبُو عَوَانَةَ، عَنْ عُمَرَ بْنِ أَبِي سَلَمَةَ، عَنْ أَبِيهِ، عَنْ أَبِي هُرَيْرَةَ، أَنَّ رَسُولَ اللهِ صلى الله عليه وسلم قَالَ: إِذَا تَمَنَّى أَحَدُكُمْ فَلْيَنْظُرْ مَا يَتَمَنَّى، فَإِنَّهُ لاَ يَدْرِي مَا يُعْطَى.
also referenced under: Hadith 794 (Reference) & Book 33, Hadith 794 (English)