Internship project: ODK Briefcase - New export types

So if we are flattening the repeats do we put everything in the same ‘main’ CSV file under independent columns or is there a better way of doing this?

It can depend on how that CSV is going to be consumed.

If users want to work with it on excel, an independent column for each repeated field would work. Say that field A is a repeat group with one instance with field B and a nested repeat group C with two instances with fields D and E. Then, the CSV would have columns:

  • A_1.B
  • A_1.C_1.D
  • A_1.C_1.E
  • A_1.C_2.D
  • A_1.C_2.E

The total number of columns would be dynamicly based on the maximum amount repeated answers and nesting levels

If the CSV is to be imported on a database with JSON support like PostgreSQL, encoding the repeats into JSON in one column would work.