It is narrated from Sayyiduna Anas bin Malik (may Allah be pleased with him) that when the Muhajirun came from Makkah to Madinah, they had nothing with them, while the Ansar were people of land and property. So the Ansar shared with them on the condition that they would give them half of their fruits every year, and they would do the work in them.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب المساقاة / 11633