Translation
(34) Sales and Trade
كتاب البيوع
(108) Chapter: The sale of a slave (for a slave) and an animal for an animal on credit
(108) باب بَيْعِ الْعَبِيدِ وَالْحَيَوَانِ بِالْحَيَوَانِ نَسِيئَةً
Sahih al-Bukhari 2228 

Narrated Anas:

Amongst the captives was Safiya. First she was given to Dihya Al-Kalbi and then to the Prophet.

حَدَّثَنَا سُلَيْمَانُ بْنُ حَرْبٍ، حَدَّثَنَا حَمَّادُ بْنُ زَيْدٍ، عَنْ ثَابِتٍ، عَنْ أَنَسٍ ـ رضى الله عنه ـ قَالَ كَانَ فِي السَّبْىِ صَفِيَّةُ، فَصَارَتْ إِلَى دَحْيَةَ الْكَلْبِيِّ، ثُمَّ صَارَتْ إِلَى النَّبِيِّ صلى الله عليه وسلم‏.‏
Reference : Sahih al-Bukhari 2228
In-book reference : Book 34, Hadith 175
USC-MSA web (English) reference : Vol. 3, Book 34, Hadith 431
  (deprecated numbering scheme)