Uploaded image for project: 'MongoDB Database Tools'
  1. MongoDB Database Tools
  2. TOOLS-794

Mongoexport will not export field from subdoc to csv

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.0.4
    • Component/s: mongoexport
    • None
    • Environment:
      OSX 10.10

      Referencing a field in a subdocument appears to be broken in version 3.0.4 of mongoexport.
      In previous versions -f subdoc.0.fieldname would export the values in the first element of subdoc. This is no longer working since I updated to 3.0.4 from 2.6.4. The following is from the docs and it states that the field can be within a subdocument.

      --fields <field1 [,field2]>, -f <field1 [,field2]>
      Specifies a field or fields to include in the export. Use a comma separated list of fields to specify multiple fields.

      For csv output formats, mongoexport includes only the specified field(s), and the specified field(s) can be a field within a sub-document.

            Assignee:
            mikeo@mongodb.com Michael O'Brien
            Reporter:
            steve.schlotter Steve Schlotter
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: