kumuluz / kumuluzee-rest

KumuluzEE REST extension for implementation of common, advanced and flexible REST API functionalities and patterns as microservices.
https://ee.kumuluz.com
Other
8 stars 4 forks source link

Not able to filter based on Date #13

Open Mohammad04 opened 4 years ago

Mohammad04 commented 4 years ago

Hi Team,

I am trying to use below filter: GET v1/customers?where=createdAt:GT:'2017-06-12T11:57:00%2B00:00'

But i am getting error message as "A filter has too many argument or is malformed"

Please let me know what is the correct Format of Date ?

zvonegit commented 4 years ago

Try with:

GET v1/customers?where=createdAt:GT:dt'2017-06-12T11:57:00%2B00:00'

Mohammad04 commented 4 years ago

@zvonegit : I tried the above suggestion. But it is also giving me the same error message. I tried debugging the QueryStringBuilder class in buildFilter() method i am getting this error may be because of the (:) in time part of the above date.

Please let me know which format will work.

Can we use the above condition with filter as well ?

I tried the above condition with filter as well i was again getting the same error.

osbeorn commented 4 years ago

I've written a test to confirm your issue but the test passes without any error. I've also tried the same on an actual live service and it also works as intented.

Which version of the library are you using?

Also, filter is the same as where.

Mohammad04 commented 4 years ago

i am using kumuluzee-rest-core version 1.3.1 maven dependency.

osbeorn commented 4 years ago

Please provide the exact error message you are receiving (the whole message). It would be helpful if you could also provide a minimal example for reproducing this issue.