Relative search with absolute time op LastUpdated


I’m trying to build a search query on tickets where:

LastUpdated < ‘-7 days’

I noticed that it searches on the current time - 7 days. So if you search at 14:00, then tickets from 7 days ago are displayed but only if they are updated before 14:00.
I really need to search on whole days (before 0:00), is this possible?

(we’re using RT 4.2)


Have you tried something like:

LastUpdated < ‘-7 days 00:00:00’

Certainly if I do searches like that with 00:00:00 replaced by (for example) 23:00:00 in the TicketSQL I get different numbers of tickets returned in our RT setup (we’re on 4.4.2 though so YMMV).


Thanks! After some trial and error I’ve got it working. Neat trick!