I have a access log, which records usernames and a timestamp at various points in the application. I want to see if I can approximate the amount of time they are spending in the application. Basically I want to join each record to the last access record based on the timestamp, so I can figure out the time difference.
I can’t think of how to join to the first record whose timestamp is less than the current record. What is the way to do this?
Try something like this: