EW 520 then QR 3577 at Barcelona
Cologne → Barcelona → Berlin
Timetable, Barcelona time
14:45EW 520 from Cologne at the gate
14:00QR 3577 to Berlin leaves the gate
23 h 15 apart on the timetable, overnight
QR 3577 leaves 23 h 15 after EW 520 arrives on the timetable: more than half a day, so not a connection we count.