FR 5817 then W4 803 at Fiumicino
Bari → Rome → Madrid
Timetable, Rome time
07:40FR 5817 from Bari at the gate
00:57W4 803 to Madrid leaves the gate
17 h 17 apart on the timetable, overnight
W4 803 leaves 17 h 17 after FR 5817 arrives on the timetable: more than half a day, so not a connection we count.