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

upsert doesn't work if shard key isn't in value

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.5.1
    • Affects Version/s: None
    • Component/s: Sharding
    • None

      db.user_agent.update({
      date: "2009-11-10",
      user_agent: "Mozilla/5.0 (compatible; Googlebot/2.1)",
      },
      { '$inc':

      {count: 1}

      ,
      '$set': {ua: {foo: "bar"}},
      '$set':

      {lv: 1}

      ,
      },

      {'upsert': 1}

      )

            Assignee:
            mathias@mongodb.com Mathias Stearn
            Reporter:
            eliot Eliot Horowitz (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: