I am writing an DateTime filter query in OData like this:
... + "$filter=SubmitTime lt datetime'2014-12-30T23:59:59.99Z'"
and met the following error:
I did follow the OData format guideline and other online references, and the string I wrote is aligned with the guideline.
So is this a problem caused by dll version? like stated in this post: WebAPI OData DateTime error
The Microsoft.OData.Edm.dll version I am using is: Runtime Version: v4.0.30319 Version: 6.3.0.0
Any ideas? Thanks!
It seems that you are using the OData library which implement OData V4. In OData V4 spec, no DateTime primitive type exist, only have DateTimeOffset.
Could you try the URL:
...?$filter=SubmitTime lt 2014-12-30T23:59:59.99Z
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With