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

Shell inserts no longer display returned WriteResult under SpiderMonkey

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.1.7
    • Component/s: Shell
    • Labels:
    • Fully Compatible
    • ALL
    • Hide
      > db.foo.insert({_id:1})
      > db.foo.insert({_id:1})
      > a = db.foo.insert({_id:1})
      > a.toString()
      WriteResult({
      	"nInserted" : 0,
      	"writeError" : {
      		"code" : 11000,
      		"errmsg" : "E11000 duplicate key error index: test.foo.$_id_ dup key: { : 1.0 }"
      	}
      })
      
      Show
      > db.foo.insert({_id:1}) > db.foo.insert({_id:1}) > a = db.foo.insert({_id:1}) > a.toString() WriteResult({ "nInserted" : 0, "writeError" : { "code" : 11000, "errmsg" : "E11000 duplicate key error index: test.foo.$_id_ dup key: { : 1.0 }" } })

      As of 2a6a8f7cf32465da072e63ee9e1272907b6bfa54 the Mongo shell no longer displays WriteResult's following the execution of a write operation.

            Assignee:
            mira.carey@mongodb.com Mira Carey
            Reporter:
            david.hows David Hows
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: