Escape all CSV fields with double quotes in user export

XMLWordPrintable

      Problem Definition

      The exported field values may contain comma (such as in username, full_name or email), and the comma possibly conflict with CSV separator.

      Suggested Solution

      Escape all fields with a pair of double quotes. This doesn't violate RFC 4180, and most of CSV library or application (e.g. Excel) can handle such a format.

      Workaround

      None. You can find entries where the number of fields (8 in this case) is larger than expected, and fix the data manually:

      awk -F ',' 'NF>8 { print $0 }' ~/Downloads/export-users.csv
      

              Assignee:
              Unassigned
              Reporter:
              K. Yamamoto (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: