Ubaydullah ibn Abdullah reported that he heard from Sayyidina Abu Hurayrah (RA) Zayd ibn Khalid (RA) and Shibl that they were with the Prophet Two men came to him, quarreling with one another. One of them stood before him and said, “I adjure you by Allah, 0 Messenger of Allah! Decide between us according to the Book of Allah His contender also uttered, he being more intelligent than the other” 0 Messenger of Allah do judge between us by Allah s Book and permit me to speak, My son was a labourer with him and committed adultery with his wife. I was informed that my son would attract the punishment of stoning to death, so by way of ransom, I gave a hundred sheep and emanicpated a slave, thereafter, I met some scholars and they told me that my son would be awarded a hundred lashes and exiled for a year while this man’s wife would be stoned to death.’ So, Allah’s Messenger (SAW) said, “By Him in whose Hand is my soul. I will surely judge between you by Allah’s Book. The hundred sheep and the slave are returnable to you. Your son will be awarded a hundred lashes and exiled for a year. And, O Unays go to the wife of this man tomorrow morning. If she confesses then stone her.” He went to her the next day. She confessed and he stoned her to death.
[Bukhari 6842, Muslim 1697]