Sahih al-Bukhari, Book 64, Hadith 310 (In-Book)

Narrated Ibn `Abbas: The Prophet left Medina (for Mecca) in the company of ten-thousand (Muslim warriors) in (the month of) Ramadan, and that was eight and a half years after his migration to Medina. He and the Muslims who were with him, proceeded on their way to Mecca. He was fasting and they were fasting, but when they reached a place called Al-Kadid which was a place of water between 'Usfan and Kudaid, he broke his fast and so did they. (Az-Zuhri said, "One should take the last action of Allah's Messenger and leave his early action (while taking a verdict.")

حَدَّثَنِي مَحْمُودٌ، أَخْبَرَنَا عَبْدُ الرَّزَّاقِ، أَخْبَرَنِي مَعْمَرٌ، قَالَ أَخْبَرَنِي الزُّهْرِيُّ، عَنْ عُبَيْدِ اللَّهِ بْنِ عَبْدِ اللَّهِ، عَنِ ابْنِ عَبَّاسٍ ـ رضى الله عنهما ـ أَنَّ النَّبِيَّ صلى الله عليه وسلم خَرَجَ فِي رَمَضَانَ مِنَ الْمَدِينَةِ، وَمَعَهُ عَشَرَةُ آلاَفٍ، وَذَلِكَ عَلَى رَأْسِ ثَمَانِ سِنِينَ وَنِصْفٍ مِنْ مَقْدَمِهِ الْمَدِينَةَ، فَسَارَ هُوَ وَمَنْ مَعَهُ مِنَ الْمُسْلِمِينَ إِلَى مَكَّةَ، يَصُومُ وَيَصُومُونَ حَتَّى بَلَغَ الْكَدِيدَ ـ وَهْوَ مَاءٌ بَيْنَ عُسْفَانَ وَقُدَيْدٍ ـ أَفْطَرَ وَأَفْطَرُوا‏.‏ قَالَ الزُّهْرِيُّ وَإِنَّمَا يُؤْخَذُ مِنْ أَمْرِ رَسُولِ اللَّهِ صلى الله عليه وسلم الآخِرُ فَالآخِرُ‏.‏

sunnah.com