Prepare the data

Before sending the data to Microreact, the dataflow will need to convert the data from Epicollect to CSV format and find the names of the columns that contain coordinate data.

In the Data Tables section of the data transformations menu, add the "Datatable to csv" and "Datatable columns" adaptors:

Connect the data argument of the "Epicollect project" to the data argument of the "Datatable to csv" and "Datatable columns" adaptors:

In the List Manipulation section of the data transformations menu, add two "Find value" adaptors. Connect the columns argument of the "Datatable columns" adaptor to list argument of both "Find value" adaptors:

Select the pattern argument of the first "Find value" adaptor:

On the right-hand side, select Bind to a value. In the input box, enter the value /^lat_/. This will attempt to find a column name starting with "lat_":

Repeat the process for the second "Find value" adaptor, but enter the value /^long_/. This will attempt to find a column name starting with "long_":

In the Data Destinations section of the data transformations menu, add an "Upload to microreact" adaptor:

Make the following connections:

  • Connect the slug argument of the "Epicollect project" adaptor to the name argument of the "Upload to microreact" adaptor. This relates the Microreact project back to its source in Epicollect.

  • Connect the csv argument of the "Datatable to csv" adaptor to data argument of the "Upload to microreact" adaptor.

  • Connect the value argument of the first "Find value" adaptor to the mapLatitude argument of the "Upload to Microreact" adaptor.

  • Connect the value argument of the second "Find value" adaptor to the mapLongitude argument of the "Upload to Microreact" adaptor.

The dataflow should now appear as follows:

The "Upload to microreact" adaptor needs a few more details. Select the idField argument:

On the right-hand side, select Bind to a value. Enter the value ec5_uuid:

Select the timelineField argument of the "Upload to microreact" adaptor:

On the right-hand side, select Bind to a value. Enter the value created_at:

Select the timelineFormat argument of the "Upload to microreact" adaptor:

On the right-hand side, select Bind to a value. Enter the value ISO 8601:

‚Äč