Sayyiduna Ibn Umar (may Allah be pleased with them both) said: "My father brought me to the Messenger of Allah (peace and blessings be upon him) on the day of Uhud when I was fourteen years old, and the Prophet (peace and blessings be upon him) did not permit me. Then he brought me on the day of al-Khandaq when I was fifteen years old, and the Messenger of Allah (peace and blessings be upon him) permitted me." Nafi' said: I related this to Umar bin Abd al-Aziz (may Allah have mercy on him), and he ordered that only boys of fifteen years be enrolled in the army.
Hadith Referenceالمعجم الكبير للطبراني / باب العين / 12985