AA 1997 then UA 5522 at O'Hare
St Louis → Chicago → Kansas City
Timetable, Chicago time
09:00AA 1997 from St Louis at the gate
08:40UA 5522 to Kansas City leaves the gate
23 h 40 apart on the timetable, overnight
UA 5522 leaves 23 h 40 after AA 1997 arrives on the timetable: more than half a day, so not a connection we count.