Sahih al-Bukhari

Sahih al-Bukhari 3423

The Statement of Allah Taa'la: "And to Dawud, We gave Sulaiman (for a son). How excellent (a) slave he was ever oft-returning in repentance (to us)" (38.30)
Arabic hadith text
حَدَّثَنِي مُحَمَّدُ بْنُ بَشَّارٍ، حَدَّثَنَا مُحَمَّدُ بْنُ جَعْفَرٍ، حَدَّثَنَا شُعْبَةُ، عَنْ مُحَمَّدِ بْنِ زِيَادٍ، عَنْ أَبِي هُرَيْرَةَ، عَنِ النَّبِيِّ صلى الله عليه وسلم ‏"‏إِنَّ عِفْرِيتًا مِنَ الْجِنِّ تَفَلَّتَ الْبَارِحَةَ لِيَقْطَعَ عَلَىَّ صَلاَتِي، فَأَمْكَنَنِي اللَّهُ مِنْهُ، فَأَخَذْتُهُ، فَأَرَدْتُ أَنْ أَرْبُطَهُ عَلَى سَارِيَةٍ مِنْ سَوَارِي الْمَسْجِدِ حَتَّى تَنْظُرُوا إِلَيْهِ كُلُّكُمْ فَذَكَرْتُ دَعْوَةَ أَخِي سُلَيْمَانَ رَبِّ هَبْ لِي مُلْكًا لاَ يَنْبَغِي لأَحَدٍ مِنْ بَعْدِي‏.‏ فَرَدَدْتُهُ خَاسِئًا ‏"‏‏.‏ عِفْرِيتٌ مُتَمَرِّدٌ مِنْ إِنْسٍ أَوْ جَانٍّ، مِثْلُ زِبْنِيَةٍ جَمَاعَتُهَا الزَّبَانِيَةُ‏.‏
Translation
Narrated Abu Huraira

The Prophet (ﷺ) said, "A strong demon from the Jinns came to me yesterday suddenly, so as to spoil my prayer, but Allah enabled me to overpower him, and so I caught him and intended to tie him to one of the pillars of the Mosque so that all of you might see him, but I remembered the invocation of my brother Solomon: 'And grant me a kingdom such as shall not belong to any other after me.' (38.35) so I let him go cursed."