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

Error message for $mul with non-numeric type is confusing

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Minor - P4 Minor - P4
    • None
    • 2.6.0-rc0
    • None
    • Fully Compatible
    • ALL
    • Hide

      var qa380_db = db.getSiblingDB("qa380");
      var coll = qa380_db.foo;
       
      coll.update({n : 0}, {$mul: {n : '' }})

      Error message: "Cannot increment with non-numeric argument:"
      Should be: "Cannot apply $mul to a value of non-numeric type."

      Show
      var qa380_db = db.getSiblingDB("qa380"); var coll = qa380_db.foo;   coll.update({n : 0}, {$mul: {n : '' }}) Error message: "Cannot increment with non-numeric argument:" Should be: "Cannot apply $mul to a value of non-numeric type."

    Description

      Based on testing (QA-380) in 2.5 and 2.6 there were many changes to the WriteResult. The error message for $mul is incorrect.

      Attachments

        Activity

          People

            Unassigned Unassigned
            jonathan.abrahams Jonathan Abrahams
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: