17 Apr
2015
17 Apr
'15
6:25 p.m.
Hello Alan.
That's what indexes are for. You should have an index on acctstoptime. With that, finding records with a non-empty stop time is relatively trivial.
Index is there of course. The issue is you have to check if the the time interval from the last session update (which I store as well) is twice longer than Interim-Update interval (just in case I lost an Interim) and the session has Acct-Status-Type Interim-Update. I will check what explain select says here...
Hmm... I'll take a deeper look into it. It might be a platform portability thing. i.e. it works on one platform, but not another.
Thanks for your effort. Regards Ales