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

Mongo interactive shell bug

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major - P3 Major - P3
    • None
    • 2.4.2
    • Shell
    • None
    • 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)

    Description

      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

      Attachments

        Activity

          People

            Unassigned Unassigned
            alex.komyagin@mongodb.com Alexander Komyagin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: