The Messenger of Allah ﷺ said, "A Dinar for a Dinar and a dirham for a dirham, with no excess between them."
أخبرنا قتيبة بن سعيد عن مالك عن موسى بن أبي تميم عن سعيد بن يسار
أن رسول الله ﷺ قال الدينار بالدينار والدرهم بالدرهم لا فضل بينهما
Muslim narrated it in "Kitab al-Musaqah, chapter on currency exchange and selling gold for silver in cash," no. 85/1588, from the hadith of Malik through this route. It is also found in the Muwatta (Yahya's recension), 632/2, and in Kubra, no. 6160.