AV 9777 then JA 5172 at Bogotá
Riohacha → Bogota → Santa Marta
Timetable, Bogota time
18:05AV 9777 from Riohacha at the gate
15:00JA 5172 to Santa Marta leaves the gate
20 h 55 apart on the timetable, overnight
JA 5172 leaves 20 h 55 after AV 9777 arrives on the timetable: more than half a day, so not a connection we count.