It is narrated from Sayyiduna Ibn Umar (may Allah be pleased with them both) that the Messenger of Allah (peace and blessings be upon him) said: "The sale of fruits (on the tree) in exchange for dates is not valid, and the sale of fruits is not valid until they have ripened well."
Hadith Referenceمسند احمد / مسند المكثرين من الصحابة / 6376