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.
abudawud:3137ʿAbbās al-ʿAnbarī > ʿUthmān b. ʿUmar > Usāmah > al-Zuhrī > Anas

The Prophet ﷺ passed by Hamzah who was disfigured (after being killed). He did not offer prayer over any martyr except him.  

أبو داود:٣١٣٧حَدَّثَنَا عَبَّاسٌ الْعَنْبَرِيُّ حَدَّثَنَا عُثْمَانُ بْنُ عُمَرَ حَدَّثَنَا أُسَامَةُ عَنِ الزُّهْرِيِّ عَنْ أَنَسٍ

أَنَّ النَّبِيَّ ﷺ مَرَّ بِحَمْزَةَ وَقَدْ مُثِّلَ بِهِ وَلَمْ يُصَلِّ عَلَى أَحَدٍ مِنَ الشُّهَدَاءِ غَيْرِهِ