DY 3503 then DY 2063 at Copenhagen
Edinburgh → Copenhagen → Riga
Timetable, Copenhagen time
22:00DY 3503 from Edinburgh at the gate
17:50DY 2063 to Riga leaves the gate
19 h 50 apart on the timetable, overnight
DY 2063 leaves 19 h 50 after DY 3503 arrives on the timetable: more than half a day, so not a connection we count.