He heard him say, "While we were in the mosque on a Friday and the Messenger of Allah ﷺ was delivering the sermon to the people, a man stood up and said, 'Messenger of Allah, the roads have been cut off, our livestock has perished, and the land has become barren. Pray to Allah to send us rain.'The Messenger of Allah ﷺ raised his hands level with his face and said, 'O Allah, send us rain.' By Allah, the Messenger of Allah ﷺ had not stepped down from the pulpit before rain poured upon us in abundance, and it kept raining that day until the following Friday.Then a man stood up, I do not know whether he was the same one who had asked the Messenger of Allah ﷺ to pray for rain or not, and said, 'Messenger of Allah, the roads have been cut off and our livestock has perished from the excess of water. Pray to Allah to hold the water back from us.'The Messenger of Allah ﷺ said, 'O Allah, around us and not upon us. Rather upon the mountains and the places where trees grow.'By Allah, no sooner had the Messenger of Allah ﷺ spoken these words than the clouds split apart until we could see nothing of them."
أخبرنا عيسى بن حماد قال حدثنا الليث عن سعيد وهو المقبري عن شريك بن عبد الله بن أبي نمر
أنه سمعه يقول بينا نحن في المسجد يوم الجمعة ورسول الله ﷺ يخطب الناس فقام رجل فقال يا رسول الله تقطعت السبل وهلكت الأموال وأجدب البلاد فادع الله أن يسقينا فرفع رسول الله ﷺ يديه حذاء وجهه فقال اللهم اسقنا فوالله ما نزل رسول الله ﷺ عن المنبر حتى أوسعنا مطرا وأمطرنا ذلك اليوم إلى الجمعة الأخرى فقام رجل لا أدري هو الذي قال لرسول الله ﷺ استسق لنا أم لا فقال يا رسول الله انقطعت السبل وهلكت الأموال من كثرة الماء فادع الله أن يمسك عنا الماء فقال رسول الله ﷺ اللهم حوالينا ولا علينا ولكن على الجبال ومنابت الشجر قال والله ما هو إلا أن تكلم رسول الله ﷺ بذلك تمزق السحاب حتى ما نرى منه شيئا
Sahih. Previously mentioned, no. 1505, and it is in Kubra, no. 1818.