Mongo interactive shell bug

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Duplicate
    • Priority: Major - P3
    • None
    • Affects Version/s: 2.4.2
    • Component/s: Shell
    • None
    • Environment:
      mongo 2.4.2rc0
    • Linux
    • Hide

      db.xep.drop()
      db.xep.insert(

      {"foo" : "bar"}

      )
      a = db.xep.findOne()
      a._id = 42
      db.xep.insert(a)
      assert.eq(db.xep.find(

      {"_id" : 42}

      ).count(), 1)

      Show
      db.xep.drop() db.xep.insert( {"foo" : "bar"} ) a = db.xep.findOne() a._id = 42 db.xep.insert(a) assert.eq(db.xep.find( {"_id" : 42} ).count(), 1)
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      In the interactive shell, find/findOne queries return objects with "abnormal" _id fields. Insert and upsert operations do not see it's presence.

      Problem is not reproducible in the mongo shell from v2.4.1

            Assignee:
            Unassigned
            Reporter:
            Alexander Komyagin (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: