From Sahih Muslim (Hadith 103):
It is narrated on the authority of Thabit that Anas said:We were forbidden in the Holy Qur'an that we should ask about anything from the Messenger of Allah (ﷺ) and then Anas reported the hadith in similar words
Reference: Muslim 103