I’m trying to write an OData filter that filters a record based on the current date and time but I can’t find a way to dynamically check for the current date and time.
When I filter like below it works fine but it’s not checking for the current date. So what i’m looking for is a way to replace 2020-07-08T13:58:16Z and 2020-07-08T14:35:54Z with some code so that it evaluates against the current date and time and not a hardcoded date.
indicium/iam/iam/appl_claim?$filter=claim_start_date_time gt 2020-07-08T13:58:16Z and claim_end_date_time lt 2020-07-08T14:35:54Z
I’ve read about the now() function but when I try to implement this I get an internal server error.
Anyone know how to fix this?
Best answer by Erwin EkkelView original