A man committed fornication with a woman. It was not known that he was married. So he was flogged. It was then known that he was married, so he was stoned to death.
Sunan Abi Dawud Book 40, Hadith 89