Anas bin Malik reported,

On the day of the Trench, the Ansar were chanting, "We are the ones who pledged allegiance to Muhammad to strive in jihad as long as we live."He responded to them, "O Allah, there is no true life except the life of the Hereafter, so honor the Ansar and the Muhajirun."

Bukhari 3796

Sahih

حدثنا آدم حدثنا شعبة عن حميد الطويل سمعت

أنس بن مالك رضي الله عنه قال

كانت الأنصار يوم الخندق تقول نحن الذين بايعوا محمدا على الجهاد ما حيينا أبدا فأجابهم اللهم لا عيش إلا عيش الآخره فأكرم الأنصار والمهاجره

البخاري 3796صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Virtues of the Ansar
Chapter
Supplication of the Prophet ﷺ for the Ansar and Muhajirun
Numbering
Darussalam 3796
Bukhari 3796