An Arabi with a booming voice came and said, "Muhammad, what about a man who loves a people but has not yet caught up with them in deeds?"The Messenger of Allah ﷺ replied, "A person will be with those whom he loves."
حدثنا محمود بن غيلان حدثنا يحيى بن آدم حدثنا سفيان عن عاصم عن زر بن حبيش
جاء أعرابي جهوري الصوت قال يا محمد الرجل يحب القوم ولما يلحق بهم فقال رسول الله ﷺ المرء مع من أحب
[Sahih]. Ahmad narrated it: 4/239, from the hadith of Yahya bin Adam, through this route.Sufyan Thawri was followed by Hammad bin Zayd, as will come later, and the hadith has many corroborating narrations.