It is narrated from Sayyiduna Abu Hurayrah (may Allah be pleased with him) that when the iqamah for the prayer was called for the Messenger of Allah (peace and blessings be upon him), the people would stand in their places before the Prophet (peace and blessings be upon him) came to his place.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2284
(a) Awn bin Kahmas narrates from his father that he said: We stood up for the prayer at Mina, but the imam had not yet come out, so some of us sat down. A shaykh from the people of Kufah said to me: "What has made you sit?" I said: "Ibn Buraydah." The shaykh said to me: "Abd al-Rahman bin Awsajah narrated to me about this from Sayyiduna al-Bara' bin Azib (may Allah be pleased with him), who said: In the time of the Messenger of Allah (peace and blessings be upon him), we would stand in rows for the prayer for a long time before he said the takbir."
Sayyiduna al-Bara' bin Azib (may Allah be pleased with him) said that the Messenger of Allah (peace and blessings be upon him) said: "Indeed Allah Almighty sends down His mercy, and His angels pray, for those who are in the first row; and there is no step better in the sight of Allah, Exalted be His praise, than the step a person walks to join a row."
(b) Something similar has also been transmitted from Sayyiduna Ali (may Allah be pleased with him). It is transmitted from Abu Khalid al-Walibi that one day Ali bin Abi Talib (may Allah be pleased with him) came out to lead us in prayer while we were standing. He (may Allah be pleased with him) said: "What is the matter that I see you standing in a daze?"
(c) Ibrahim al-Nakha'i (may Allah have mercy on him) was asked whether they should wait for the imam standing or sitting. He said: "They should wait sitting."
What seems most likely is that the Companions (may Allah be pleased with them) used to stand up for the prayer before the Prophet (peace and blessings be upon him) came out, and would take their places before he took his place. Then he commanded them: "Do not stand until you see me." He (peace and blessings be upon him) gave this command to make things easier for them.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2285
Sayyiduna Abdullah bin Abi Qatadah narrates from his father (Sayyiduna Abu Qatadah (may Allah be pleased with him)) that the Prophet (peace and blessings be upon him) said: "When the prayer is begun, do not stand until you see me."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2286
Abdullah bin Abi Qatadah (may Allah have mercy on him) narrates from his father (Sayyiduna Abu Qatadah (may Allah be pleased with him)) that he (peace and blessings be upon him) said: "When the iqamah has been called, do not stand until you see me, that I have come out for the prayer."
(b) Likewise al-Walid bin Muslim narrated this hadith from Shayban, from Yahya, and in it is: "Until you see that I have come out for the prayer."
In the narration transmitted from Hajjaj there are the words 'qad kharajtu' (I have indeed come out), and in another narration, which some students of fiqh have transmitted, the words are 'hatta tarawni qa'iman fi al-saff' (until you see me standing in the row).
(c) When Sayyiduna Anas bin Malik (may Allah be pleased with him) heard 'qad qamat al-salah' (the prayer has indeed begun), he would immediately stand up for the prayer.
(d) Sayyiduna al-Husayn bin Ali (may Allah be pleased with them both) also used to do the same. This is the view of Ata' and al-Hasan.
The wording 'until you see me standing in the row' has not reached us.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 2287