FR 1977 then FR 1901 at Dublin
Riga → Dublin → Krakow
Timetable, Dublin time
23:10FR 1977 from Riga at the gate
17:55FR 1901 to Krakow leaves the gate
18 h 45 apart on the timetable, overnight
FR 1901 leaves 18 h 45 after FR 1977 arrives on the timetable: more than half a day, so not a connection we count.