0

For MarkLogic Query-By-Example, I can search for all entries that contains the specific email address like this:

{
 "$query":
   {
      "emailAddress":"[email protected]"
   }
}

My question is how can you negate this search, for this specific example, how can I find all the results that does NOT contain emailAddress with value: '[email protected]' ? Is there a not operator for MarkLogic Query By Example JSON format?

1 Answer 1

2

Try $not or $nor: https://docs.marklogic.com/guide/search-dev/qbe mentions $nor, but looking at qbe-model.xqy I think that's a typo and it should be $not.

There's also a $ne for range query, in case that helps.

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.