Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-13511

$and and $nin does not work well together

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.4.9
    • Component/s: Querying
    • None
    • ALL
    • Hide

      Run the query above. Query should not return any document. It returns a document if _id exists.

      Show
      Run the query above. Query should not return any document. It returns a document if _id exists.

      The following query still returns a document, despite logically it should not:

      { '$and': [

      { _id: 'qSEhNMGPv38AY4gCR' }

      , {_in: { '$nin': [ 'qSEhNMGPv38AY4gCR' ] }}] }

            Assignee:
            Unassigned Unassigned
            Reporter:
            mitar NOVALUE Mitar
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: