TK 9588 then AY 5797 at San Francisco
Portland (Oregon) → San Francisco → New York JFK
Timetable, San Francisco time
15:15TK 9588 from Portland (Oregon) at the gate
12:25AY 5797 to New York JFK leaves the gate
21 h 10 apart on the timetable, overnight
AY 5797 leaves 21 h 10 after TK 9588 arrives on the timetable: more than half a day, so not a connection we count.