QR 3717 then IB 418 at Barcelona
Rome → Barcelona → Madrid
Timetable, Barcelona time
19:55QR 3717 from Rome at the gatealso IB 5343, LL 5343, VY 6013
18:00IB 418 to Madrid leaves the gatealso IB 418S, LA 1585, CX 1836, LL 3018, VY 5082, AV 6019, QR 6562
22 h 05 apart on the timetable, overnight
IB 418 leaves 22 h 05 after QR 3717 arrives on the timetable: more than half a day, so not a connection we count.