mysql - Looking up times in DB based off actual time or actual time including Delay -
i looking way able grab rows database time. two columns exist: time - scheduled time delay - +seconds time delayed. let's say: id,time,delay 1,18:23,360 2,18:25,0 3,17:15,-60 now, let's searching buses after arriving at/after 18:25, how include these 2 results: 2,18:25,0 1,18:23,360 (note: 18:23 + 360 seconds = 18:29) in query like where `time` >= '18:23' thanks select * [table] date_add(time,interval timedelay second) >= '18:25:00' mysql date_add function