Ikrimah reports from Ibn Abbas (may Allah be pleased with them both): I travelled with the Prophet (peace and blessings be upon him), and during a stay of seventeen days he (peace and blessings be upon him) shortened the prayer.
Abu Mu'awiyah narrated this same hadith from Asim al-Ahwal, and in most of the narrations (from him) he mentioned nineteen days.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصلاة / 5462