mqlrun yields inconsistent with mongod when field name is empty

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Won't Fix
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Execution
    • ALL
    • Hide

      $ ./mqlrun -j -e '[]' empty_field_names.bson # this bson file is attached

      { a: 1 }

      { : 1 }
      { : 2 }

      $ ./mqlrun -j -e '[{$match: {"":1}}]' empty_field_names.bson # no results

       

      $ ./mqlrun -j -e '[{$match: {"a":1}}]' empty_field_names.bson

      { a: 1 }
      Show
      $ ./mqlrun -j -e '[]' empty_field_names.bson # this bson file is attached { a: 1 } { : 1 } { : 2 } $ ./mqlrun -j -e '[{$match: {"":1 }}]' empty_field_names.bson # no results   $ ./mqlrun -j -e '[{$match: {"a":1 }}]' empty_field_names.bson { a: 1 }
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The empty string ("") is a valid field name in MongoDB and a user can query off of it using a match pipeline stage when running on a mongod. However, if a document is passed to mqlrun with the empty string as a field name, then that field is effectively ignored, rather than queried off of.

      This was discovered while investigating a fix for MHOUSE-3552.

            Assignee:
            [DO NOT USE] Backlog - Query Execution
            Reporter:
            Shakil Rafi
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: