The Prophet ﷺ said, "Whoever makes two sales in one transaction must take the lesser of the two prices, otherwise it is usury."
حدثنا أبو بكر بن أبي شيبة عن يحيى بن زكريا عن محمد بن عمرو عن أبي سلمة
قال النبي ﷺ من باع بيعتين في بيعة فله أوكسهما أو الربا
No references are available.
[Its isnad is hasan]. Bayhaqi (5/343) narrated it from the hadith of Abu Dawud through him, and Ibn Hibban declared it sahih (1110), as did Hakim, who said it meets the standard of Muslim (2/45), and Dhahabi agreed with him. Tirmidhi (1231) and Nasai (7/295, 4636) also narrated it with the wording, "He forbade two sales in one sale," and Tirmidhi said, hasan sahih.