FR 3008 then QS 1057 at Madrid
Milan → Madrid → Prague
Timetable, Madrid time
19:50FR 3008 from Milan at the gate
13:55QS 1057 to Prague leaves the gate
18 h 05 apart on the timetable, overnight
QS 1057 leaves 18 h 05 after FR 3008 arrives on the timetable: more than half a day, so not a connection we count.