Block field names with dollar sign prefix at insert time

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Duplicate
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      As reported in CXX-443, with MongoDB 2.6 and the right driver (in this case the 26compat C++ driver) it is possible to insert a document that contains a field prefixed with a dollar sign, whereas for a corresponding update the server returns an error:

      "The dollar ($) prefixed field '$unwind' in 'pipeline.0.$unwind' is not valid for storage."

      This seems inconsistent and unintuitive. The server should prevent dollar sign prefixed fields (and more generally, fields containing any reserved characters) from entering the system.

              Assignee:
              Unassigned
              Reporter:
              Jon Rangel (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: