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.
bayhaqi:19825Abū ʿAbdullāh al-Ḥāfiẓ And ʾAbū Saʿīd b. Abū ʿAmr > Abū al-ʿAbbās Muḥammad b. Yaʿqūb > Aḥmad b. ʿAbd al-Ḥamīd al-Ḥārithī > Abū Usāmah > al-Walīd b. Kathīr > Nāfiʿ a freed slave of ʿAbdullāh b. ʿUmar > Ibn ʿUmar > Rasūl Allāh

[Machine] The Messenger of Allah ﷺ caught up with Umar while he was on a journey, taking an oath by his father. When the Messenger of Allah ﷺ heard this, he said, "Hold on, for Allah has prohibited you from swearing by your fathers. Whoever swears, let him swear by Allah or remain silent."  

البيهقي:١٩٨٢٥أَخْبَرَنَا أَبُو عَبْدِ اللهِ الْحَافِظُ وَأَبُو سَعِيدِ بْنُ أَبِي عَمْرٍو قَالَا ثنا أَبُو الْعَبَّاسِ مُحَمَّدُ بْنُ يَعْقُوبَ ثنا أَحْمَدُ بْنُ عَبْدِ الْحَمِيدِ الْحَارِثِيُّ ثنا أَبُو أُسَامَةَ عَنِ الْوَلِيدِ بْنِ كَثِيرٍ حَدَّثَنِي نَافِعٌ مَوْلَى عَبْدِ اللهِ بْنِ عُمَرَ أَنَّ ابْنَ عُمَرَ ؓ حَدَّثَهُمْ أَنَّ

رَسُولَ اللهِ ﷺ أَدْرَكَ عُمَرَ ؓ وَهُوَ فِي رَكْبٍ وَهُوَ يَحْلِفُ بِأَبِيهِ فَلَمَّا سَمِعَهُ رَسُولُ اللهِ ﷺ قَالَ مَهْلًا فَإِنَّ اللهَ قَدْ نَهَاكُمْ أَنْ تَحْلِفُوا بِآبَائِكُمْ مَنْ حَلَفَ فَلْيَحْلِفْ بِاللهِ أَوْ لِيَسْكُتْ  

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

See similar narrations below:

Collected by Mālik
malik:22-16Yaḥyá > Mālik > Nāfiʿ > ʿAbdullāh b. ʿUmar

Yahya related to me from Malik from Nafi from Abdullah ibn Umar that one time the Messenger of Allah ﷺ was speaking to Umar ibn al-Khattab while he was travelling with a troop and Umar swore by his father and he (the Messenger) said, "Allah forbids you to swear by your fathers. If anyone swears, let him swear by Allah or keep silent."  

مالك:٢٢-١٦حَدَّثَنِي يَحْيَى عَنْ مَالِكٍ عَنْ نَافِعٍ عَنْ عَبْدِ اللَّهِ بْنِ عُمَرَ

أَنَّ رَسُولَ اللَّهِ ﷺ أَدْرَكَ عُمَرَ بْنَ الْخَطَّابِ رضى الله عنه وَهُوَ يَسِيرُ فِي رَكْبٍ وَهُوَ يَحْلِفُ بِأَبِيهِ فَقَالَ رَسُولُ اللَّهِ ﷺ إِنَّ اللَّهَ يَنْهَاكُمْ أَنْ تَحْلِفُوا بِآبَائِكُمْ فَمَنْ كَانَ حَالِفًا فَلْيَحْلِفْ بِاللَّهِ أَوْ لِيَصْمُتْ