I have a table with user_id, session_start and session_end values.
I have a list of times in a file. For example, the list will look like the following:
2015-08-20 00:00:00
2015-08-20 00:15:00
2015-08-20 00:30:00
2015-08-20 00:45:00
So want to find all users who are logged in between that time and 15 minutes later, so all users logged in between (2015-08-20 00:00:00 and 2015-08-20 00:15:00, etc., etc.)
Session table looks like the following:
user_id ---- session_start ---- session_end
123 2015-08-20 00:01:00 2015-08-20 00:14:49
456 2015-08-20 00:17:31 2015-08-20 00:29:30
Query assistance would be quite helpful.