BA 1499 then IB 712 at Heathrow
Glasgow → London → Madrid
Timetable, London time
09:50BA 1499 from Glasgow at the gate
09:15IB 712 to Madrid leaves the gate
23 h 25 apart on the timetable, overnight
IB 712 leaves 23 h 25 after BA 1499 arrives on the timetable: more than half a day, so not a connection we count.