Sayyiduna Abdullah bin Mas'ud (may Allah be pleased with him) narrates from the Prophet (peace and blessings be upon him) that he (peace and blessings be upon him) said: "There is no envy (ghibtah, i.e. praiseworthy emulation) except in two cases: a man whom Allah has given wealth and has empowered him to spend it in the way of truth (that is, granted him the ability to spend it generously), and a man whom Allah has given wisdom, so he acts according to it and teaches it to others."
Hadith Referenceالمعجم الأوسط / باب الألف / 1712
Hadith Takhrij«أخرجه البخاري فى «صحيحه» برقم: 73، 1409، 7141، 7316، ومسلم فى «صحيحه» برقم: 815، 816، وابن حبان فى «صحيحه» برقم: 90، والنسائي فى «السنن الكبرى» برقم: 5809، وابن ماجه فى «سننه» برقم: 4208، والبيهقي فى «السنن الكبرى» برقم: 20221، وأحمد فى «مسنده» برقم: 3725، 4191، والطيالسي فى «مسنده» برقم: 367، والحميدي فى «مسنده» برقم: 99، وأبو يعلى فى «مسنده» برقم: 5078، 5186، 5227، والبزار فى «مسنده» برقم: 1890، والطحاوي فى «شرح مشكل الآثار» برقم: 458»