The Messenger of Allah ﷺ said, "Hold fast to this knowledge before it is taken away. Its being taken away means that it is lifted up." He then joined his middle finger and the one next to the thumb together like this, and said, "The scholar and the student are partners in reward, and there is no good in the rest of the people."
حدثنا هشام بن عمار حدثنا صدقة بن خالد حدثنا عثمان بن أبي عاتكة عن علي بن يزيد عن القاسم
قال رسول الله ﷺ عليكم بهذا العلم قبل أن يقبض وقبضه أن يرفع وجمع بين إصبعيه الوسطى والتي تلي الإبهام هكذا ثم قال العالم والمتعلم شريكان في الأجر ولا خير في سائر الناس
No references are available.
[Its isnad is very daif] Tabarani narrated it in al-Kabir: 8/62, no: 7875, from the hadith of Uthman bin Abu Atikah, through this chain. Ali bin Yazid is very daif, and likewise his student.