Abdullah bin Abd al-Rahman narrates: It has reached me that Luqman the Wise used to say: "O my son! Do not acquire knowledge in order to boast with it before the scholars, or to argue with the ignorant by means of it, or to show off with it in gatherings."
Ahmad recorded it, and its chain is munqati' (disconnected), as you can see.
Hadith Referenceمجمع الزوائد ومنبع الفوائد / كتاب العلم / 867