Sunan an-Nasa'i, Volume 1, Book 1, Hadith 156 (DarusSalam)

It was narrated from Al-Miqdad bin Al-Aswad that 'Ali told him to ask the Messenger of Allah about a man who comes close to his wife and prostatic fluid comes out of him - what should he do? ('Ali said: ) For his daughter is married to me and I feel too shy to ask him. So I asked the Messenger of Allah about that and he said: "If any one of you experiences that, let him sprinkle water on his private part and perform Wudu' as for Salah."

أَخْبَرَنَا عُتْبَةُ بْنُ عَبْدِ اللَّهِ الْمَرْوَزِيُّ، عَنْ مَالِكٍ، - وَهُوَ ابْنُ أَنَسٍ - عَنْ أَبِي النَّضْرِ، عَنْ سُلَيْمَانَ بْنِ يَسَارٍ، عَنِ الْمِقْدَادِ بْنِ الأَسْوَدِ، أَنَّ عَلِيًّا، أَمَرَهُ أَنْ يَسْأَلَ، رَسُولَ اللَّهِ صلى الله عليه وسلم عَنِ الرَّجُلِ إِذَا دَنَا مِنْ أَهْلِهِ فَخَرَجَ مِنْهُ الْمَذْىُ مَاذَا عَلَيْهِ فَإِنَّ عِنْدِي ابْنَتَهُ وَأَنَا أَسْتَحِي أَنْ أَسَأَلَهُ فَسَأَلْتُ رَسُولَ اللَّهِ صلى الله عليه وسلم عَنْ ذَلِكَ فَقَالَ ‏ "‏ إِذَا وَجَدَ أَحَدُكُمْ ذَلِكَ فَلْيَنْضَحْ فَرْجَهُ وَيَتَوَضَّأْ وُضُوءَهُ لِلصَّلاَةِ ‏" ‏ ‏.‏

sunnah.com

also referenced under: Book 1, Hadith 157 (In-Book)