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

Read commands on non-existing collections return different results with Namespace or UUID

    • Type: Icon: Bug Bug
    • Resolution: Works as Designed
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing
    • ALL
    • Hide

      Start up a replica set and run the following commands, the first will return ok but an empty set of documents and the second will throw NamespaceNotFound.

      db.runCommand({find: "foo"})

      db.runCommand({find: UUID()})

      Show
      Start up a replica set and run the following commands, the first will return ok but an empty set of documents and the second will throw NamespaceNotFound. db.runCommand({find: "foo"}) db.runCommand({find: UUID()})

      When running a find command on a collection that does not exist, we typically return an ok result with an empty set of documents. However, if this query is done via uuid rather than namespace, we will return NamespaceNotFound.

       

            Assignee:
            Unassigned Unassigned
            Reporter:
            allison.easton@mongodb.com Allison Easton
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: