Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
ibnmajah:3695Abū Bakr b. Abū Shaybah > ʿAbdullāh b. Numayr > ʿUbaydullāh b. ʿUmar > Saʿīd b. Abū Saʿīd al-Maqburī > Abū Hurayrah

"a man entered the masjid, and the Messenger of Allah ﷺ was sitting in a corner of the mosque. He prayed, then he came and greeted him with Salam(peace), and he said: 'Wa 'alaikassalm."  

ابن ماجة:٣٦٩٥حَدَّثَنَا أَبُو بَكْرِ بْنُ أَبِي شَيْبَةَ حَدَّثَنَا عَبْدُ اللَّهِ بْنُ نُمَيْرٍ حَدَّثَنَا عُبَيْدُ اللَّهِ بْنُ عُمَرَ حَدَّثَنَا سَعِيدُ بْنُ أَبِي سَعِيدٍ الْمَقْبُرِيُّ عَنْ أَبِي هُرَيْرَةَ

أَنَّ رَجُلاً دَخَلَ الْمَسْجِدَ وَرَسُولُ اللَّهِ ﷺ جَالِسٌ فِي نَاحِيَةِ الْمَسْجِدِ فَصَلَّى ثُمَّ جَاءَ فَسَلَّمَ فَقَالَ وَعَلَيْكَ السَّلاَمُ  


See similar narrations below:

Collected by Tirmidhī
tirmidhi:2692Isḥāq b. Manṣūr > ʿAbdullāh b. Numayr > ʿUbaydullāh b. ʿUmar > Saʿīd al-Maqburī > Abū Hurayrah

"A man enter the Masjid and performed Salat while the Messenger of Allah ﷺ was sitting at the back of the Masjid. Then he came to greet him, so the Prophet ﷺ said: "Wa Alaikum (and upon you); go back and pray for indeed you have not prayed.'" And he mentioned the Hadith in its entirety.  

الترمذي:٢٦٩٢حَدَّثَنَا إِسْحَاقُ بْنُ مَنْصُورٍ أَخْبَرَنَا عَبْدُ اللَّهِ بْنُ نُمَيْرٍ حَدَّثَنَا عُبَيْدُ اللَّهِ بْنُ عُمَرَ عَنْ سَعِيدٍ الْمَقْبُرِيِّ عَنْ أَبِي هُرَيْرَةَ قَالَ

دَخَلَ رَجُلٌ الْمَسْجِدَ وَرَسُولُ اللَّهِ ﷺ جَالِسٌ فِي نَاحِيَةِ الْمَسْجِدِ فَصَلَّى ثُمَّ جَاءَ فَسَلَّمَ عَلَيْهِ فَقَالَ رَسُولُ اللَّهِ ﷺ وَعَلَيْكَ ارْجِعْ فَصَلِّ فَإِنَّكَ لَمْ تُصَلِّ فَذَكَرَ الْحَدِيثَ بِطُولِهِ  

قَالَ أَبُو عِيسَى هَذَا حَدِيثٌ حَسَنٌ وَرَوَى يَحْيَى بْنُ سَعِيدٍ الْقَطَّانُ هَذَا عَنْ عُبَيْدِ اللَّهِ بْنِ عُمَرَ عَنْ سَعِيدٍ الْمَقْبُرِيِّ فَقَالَ عَنْ أَبِيهِ عَنْ أَبِي هُرَيْرَةَ وَلَمْ يَذْكُرْ فِيهِ فَسَلَّمَ عَلَيْهِ وَقَالَ وَعَلَيْكَ قَالَ وَحَدِيثُ يَحْيَى بْنِ سَعِيدٍ أَصَحُّ