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

Improve mongoexport help output for csv

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Trivial - P5
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0.0-rc10
    • Component/s: mongoexport
    • Labels:
      None
    • Sprint:
      Iteration 0

      Description

      Using the --csv option requires that fields be specified using -f. This makes sense and if you don't specify fields mongoexport spits out a short error message:

      ./mongoexport -d bi -c game_event -o st_action.csv --csv
      connected to: 127.0.0.1
      assertion: 9998 you need to specify fields

      However, the help output doesn't currently mention that -csv requires -f:

      -f [ --fields ] arg comma separated list of field names e.g. -f
      name,age
      --csv export to csv instead of json

      The help output should mention that you have to use -f with --csv and explain why that is the case.

        Activity

        Hide
        xgen-internal-githook Githook User added a comment -

        Author:

        {u'username': u'mpobrien', u'name': u"mike o'brien", u'email': u'mpobrien005@gmail.com'}

        Message: TOOLS-84 improve mongoexport help output for CSV
        Branch: master
        https://github.com/mongodb/mongo-tools/commit/586c00ef09c32c77907bd20d722049ed23065398

        Show
        xgen-internal-githook Githook User added a comment - Author: {u'username': u'mpobrien', u'name': u"mike o'brien", u'email': u'mpobrien005@gmail.com'} Message: TOOLS-84 improve mongoexport help output for CSV Branch: master https://github.com/mongodb/mongo-tools/commit/586c00ef09c32c77907bd20d722049ed23065398
        Hide
        mpobrien Michael O'Brien added a comment -

        Fixed. Added note on the "-f" help text specifying that its required when using the CSV output format.

        Show
        mpobrien Michael O'Brien added a comment - Fixed. Added note on the "-f" help text specifying that its required when using the CSV output format.

          People

          • Assignee:
            Unassigned
            Reporter:
            behackett Bernie Hackett
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Agile