You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Filter criteria $or operator not working

Accepted answer
36
Views
5
Comments
edited Mar 17, 2019 6:49PM in Visual Builder 5 comments

Summary

Rest endpoint filter criteria with $or operator doesnt work

Content

I am trying to filter REST endpoint of BO. I am successful when there is only one criteria.

But fail when the same filter is with 2 criteria with an $or operator. It works well with $and operator. 

CODE:

{
 "filter": {
  "op": "$or",
  "criteria": [
   {
    "value": "{{ $chain.variables.selectedCollection }}",
    "op": "$eq",
    "attribute": "collection"
   },
   {
    "value": "{{ $application.variables.currentDate }}",
    "op": "$ge",
    "attribute": "endDate"
   }
  ]
 }
}

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!