Abu al-Ash'ath al-San'ani narrates from Sayyiduna Ubadah bin al-Samit (may Allah be pleased with him) that he was present among the people while they were selling vessels of gold and silver (on credit) until (the payment of) the stipends. Sayyiduna Ubadah (may Allah be pleased with him) said: I heard the Messenger of Allah (peace and blessings be upon him) say: "Sell gold for gold, silver for silver, wheat for wheat, barley for barley, dates for dates and salt for salt, equal for equal. Whoever gives more or asks for more has taken usury (riba). When these kinds differ, sell them however you wish, hand to hand; there is no harm in it: gold for silver, hand to hand, however you wish; wheat for barley however you wish, hand to hand; and salt for dates however you wish."
This is an authentic narration that explains (the matter).
Hadith Referenceالسنن الكبرى للبيهقي / كتاب البيوع / 10504