QR 3774 then IB 5852 at Barcelona
Torino → Barcelona → Edinburgh
Timetable, Barcelona time
20:25QR 3774 from Torino at the gatealso IB 5811, LL 5811, VY 6129
17:50IB 5852 to Edinburgh leaves the gatealso LL 5852, VY 7752, BA 8102
21 h 25 apart on the timetable, overnight
IB 5852 leaves 21 h 25 after QR 3774 arrives on the timetable: more than half a day, so not a connection we count.