0

Trying to implement a country blacklist, but it's not clear to me how to query for a negative match on an array field using the Parse REST API. The countries being an array key.

blacklistCountries = [ "CN", "KP" ]

Is there something like $not?

where={ blacklistCountries: { $not: "CN" } } 

1 Answer 1

2

I think what you want is $ne (not equal to) as described in Query Constraints:

where={"blacklistCountries":{"$ne":"CN"}}
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.