Sayyiduna Ibn Umar (may Allah be pleased with them both) said: I used to sell camels at al-Baqi'. I would sell for dinars but take dirhams, and sell for dirhams but receive dinars. A doubt about this arose in my heart. I came to the Messenger of Allah (peace and blessings be upon him) while he (peace and blessings be upon him) was in the house of Sayyidah Hafsah (may Allah be pleased with her) — or he said: when he (peace and blessings be upon him) came out of the house of Sayyidah Hafsah (may Allah be pleased with her) — and I said: O Messenger of Allah (peace and blessings be upon him)! Wait, I want to ask you something. I sell camels at al-Baqi'; I sell for dinars and receive dirhams, and I sell for dirhams but receive dinars. He (peace and blessings be upon him) said: "There is no harm, if it is at that day's rate, as long as you two do not part while something remains (outstanding) between you."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب البيوع / 10513