FR 8385 then FR 2507 at Barcelona
Budapest → Barcelona → Cologne
Timetable, Barcelona time
18:00FR 8385 from Budapest at the gate
17:50FR 2507 to Cologne leaves the gate
23 h 50 apart on the timetable, overnight
FR 2507 leaves 23 h 50 after FR 8385 arrives on the timetable: more than half a day, so not a connection we count.