Sahih al-Bukhari 4946
Narrated `Ali:
While the Prophet (ﷺ) was in a funeral procession, he took a small stick and started scraping the earth 
with it and said, "There is none among you but has his place written for him, either in the Hell Fire or 
in Paradise." They (the people) said, "Allah's Messenger (ﷺ)! Shall we depend on this (and leave work)?" He 
replied. "Carry on doing (good deeds), for everybody will find easy (to do) such deeds as will lead 
him to his destined place." The Prophet (ﷺ) then recited:-- 
'As for him who gives (in charity) and keeps his duty to Allah, and believes in the Best 
Reward.'.....(92.5-10)
حَدَّثَنَا بِشْرُ بْنُ خَالِدٍ، أَخْبَرَنَا مُحَمَّدُ بْنُ جَعْفَرٍ، حَدَّثَنَا شُعْبَةُ، عَنْ سُلَيْمَانَ، عَنْ سَعْدِ بْنِ عُبَيْدَةَ، عَنْ أَبِي عَبْدِ الرَّحْمَنِ السُّلَمِيِّ، عَنْ عَلِيٍّ ـ رضى الله عنه ـ عَنِ النَّبِيِّ صلى الله عليه وسلم‏.‏ أَنَّهُ كَانَ فِي جَنَازَةٍ فَأَخَذَ عُودًا يَنْكُتُ فِي الأَرْضِ فَقَالَ ‏"‏ مَا مِنْكُمْ مِنْ أَحَدٍ إِلاَّ وَقَدْ كُتِبَ مَقْعَدُهُ مِنَ النَّارِ أَوْ مِنَ الْجَنَّةِ ‏"‏‏.‏ قَالُوا يَا رَسُولَ اللَّهِ أَفَلاَ نَتَّكِلُ قَالَ ‏"‏ اعْمَلُوا فَكُلٌّ مُيَسَّرٌ ‏{‏فَأَمَّا مَنْ أَعْطَى وَاتَّقَى * وَصَدَّقَ بِالْحُسْنَى‏}‏ الآيَةَ‏.‏ قَالَ شُعْبَةُ وَحَدَّثَنِي بِهِ مَنْصُورٌ فَلَمْ أُنْكِرْهُ مِنْ حَدِيثِ سُلَيْمَانَ‏"‏‏.‏