W4 6013 then FR 7071 at Madrid
Rome → Madrid → Gdansk
Timetable, Madrid time
19:55W4 6013 from Rome at the gate
10:15FR 7071 to Gdansk leaves the gate
14 h 20 apart on the timetable, overnight
FR 7071 leaves 14 h 20 after W4 6013 arrives on the timetable: more than half a day, so not a connection we count.