The Messenger of Allah ﷺ said, "Whoever acquires knowledge that should be sought for the sake of Allah , yet learns it only to gain some worldly benefit, will not even smell the fragrance of Paradise on the Day of Resurrection."
قال رسول الله ﷺ: من تعلم علما مما يبتغي به وجه الله عز وجل، لا يتعلمه إلا ليصيب به عرضا من الدنيا، لم يجد عرف الجنة يوم القيامة.
Reported by Abu Dawud (3664) and Ibn Majah (252), both through Siraj bin Numan, who said, Fulayh bin Sulayman told us, from Abdullah bin Abdul-Rahman bin Mamar Abu Tawala, from Saeed bin Yasar, from Abu Hurairah, and he related it.Ibn Hibban (78) and Hakim (1/85) graded it sahih, and both reported it through Ibn Wahb, who said, Abu Yahya Fulayh bin Sulayman informed me, with his chain, similarly. Hakim said, "This is a sahih hadith, its chain consists of trustworthy narrators meeting the standard of the two Shaykhs, though they did not include it, and a group besides Ibn Wahb have given it a full chain and connected it from Fulayh." End of quote.It was also reported by Khatib in his books Al-Faqih wal-Mutafaqqih (811), Tarikh Baghdad (5/346–347), and Iqtida al-Ilm al-Amal (102), and by Imam Ahmad (2/338), all of them through various routes from Fulayh bin Sulayman, with his chain, similarly.Fulayh bin Sulayman is a disputed narrator, most scholars judging him daif, but Ibn Adi said, He has sound hadiths, and Daraqutni said, They differ over him, but there is no harm in him, and Ibn Hibban mentioned him among the trustworthy narrators (7/324), and Hafiz said, Truthful but prone to frequent error.I say, in my view he is daif regarding legal rulings when he narrates alone, but there is no harm in him regarding matters of virtue when he has corroborating narrations, and this is one such case, and Hakim has indicated, as will be mentioned, the existence of corroborating narrations for it.