Qays bin Abbad reported,

While I was in the mosque standing in the front row, a man pulled me sharply from behind, moved me aside, and took my place. By Allah, I could not focus on my prayer.When the prayer ended, I saw that it was Ubayy bin Kaab. He said, "Young man, may Allah not bring you any harm. This is a covenant from the Prophet ﷺ to us, that we should stand directly behind him."Then he turned toward the qiblah and said, "The people of the knot are ruined, by the Lord of the Kaabah," repeating it three times. Then he said, "By Allah, I do not grieve for them, but I grieve for those they have led astray."I asked, "Abu Yaqub, who does he mean by the people of the knot?"He replied, "The rulers."

Azami 2298

Sahih

عن قيس بن عباد قال

بينا أنا في المسجد في الصف المقدم فجبذني رجل من خلفي جبدة، فنحاني، وقام مقامي. فوالله ما عقلت صلاتي. فلما انصرف فإذا هو أبي بن كعب، فقال: يا فتى لا يسؤك الله: إن هذا عهد من النبي الله ﷺ إلينا أن نليه، ثم استقبل القبلة، فقال: هلك أهل العقد ورب الكعبة ثلاثا ثم قال: والله ما عليهم آسى، ولكن آسى على من أضلوا. قلت: يا أبا يعقوب! ما يعني بأهل العقدة؟ قال: الأمراء.

الأعظمي 2298صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Prayer
Chapter
Leadership
Section
Those who should stand closest to the imam in the row
Numbering
Jami al-Kamil 2298 (2nd edition)
Azami 2298