Abu Hurairah reported,

The Messenger of Allah ﷺ said, "A man bought a piece of property from another man, and the buyer found in it a jar filled with gold.The one who had bought the property said, 'Take your gold from me. I bought only the land from you, I did not buy the gold.'But the one who had sold the land said, 'I sold you the land and whatever is in it.'So they took their dispute to another man, and the one they brought it to asked, 'Do you have children?'One of them said, 'I have a son.'The other said, 'I have a daughter.'He said, 'Marry the boy to the girl, spend on the two of them from this gold, and give the rest in charity.'"

Ahmad 8191

Sahih

وقال رسول الله ﷺ اشترى رجل من رجل عقارا له فوجد الرجل الذي اشترى العقار في عقاره جرة فيها ذهب فقال الذي اشترى العقار خذ ذهبك مني إنما اشتريت منك الأرض ولم أبتع منك الذهب وقال الذي باع الأرض إنما بعتك الأرض وما فيها قال فتحاكما إلى رجل فقال الذي تحاكما إليه ألكما ولد قال أحدهما لي غلام وقال الآخر لي جارية قال أنكح الغلام الجارية وأنفقوا على أنفسهما منه وتصدقا

أحمد 8191صحيح
Contents
Reference
Commentary
Ayat
Collection
Musnad Ahmad
Book
Abu Hurairah
Numbering
Darussalam 8191
Ahmad 8191