CSV export

I want to share some experiences about CSV export.

Action
You can use an Action “App: export this view to a CSV file (not a row-level action)”.

PRO:

  • This will download the actual view. So you don’t have to prepare a Template for the CSV.
  • By using a slice, you can control the column order.

CONTRA:

  • You cannot control the file name.
  • The CSV file will always be comma separated. You cannot change it to semicolon for example.

Workflow / Report
In Workflow or Report you can use “Save File” and “CSV” as the HTTP Content Type.

PRO:

  • You can control the file name.
  • You can disable the timestamp. With that, the new CSV will override the old. You always have the most recent file.
  • You can control the separator: In the Template just use for example semicolon instead of comma.
  • You can hide the header: In the Template just delete the header.
  • You can add Lists: In the Template just add another Select expression.
3 Likes

Additional Pro with “save file”… it will open the CSV as normal spreadsheet. No need to SPLIT data.

The only reason I use the Action is when the user wants the ability to view the CSV table on the device in-app. Otherwise you need to email and open another app. Wish the CSV action allowed more control…

My experience with the action is that it does NOT export the view… It forces the key to be included in the file, and it shows all columns in the table/slice. So if I create a table view and only have 5 columns, and am not showing the key… It’ll just dump out everything filtered…

1 Like

I can see the need to tailor the CSV output (without the extra steps of creating specific views just for this)…