Importing survey data

Importing and Exporting Survey Responses
mWater allows you to import and export survey responses using Excel or CSV file formats to work with data outside of the mWater platform.  The user can do this via the Import Responses and Export Responses functions on a survey's Responses tab. 

Importing responses

Survey data can be imported using Microsoft Excel workbook templates you can download from the Survey Responses tab.  This function gives the user freedom to work on survey data and responses outside of mWater and bring them into mWater later.

Preparing data for import

  1. Click on the survey you want to import data into on the Surveys tab.
  2. Click on the 'Responses' tab and click on the 'Import Responses' button, which will open a dialog box.  Then select options and click on 'Download Template' (Step 2).
  3. Locate and open the downloaded .xls file and conduct your survey using the template, or copy in the data from another file.

Importing survey data into mWater

  1. Click on the survey you want to import data into on the Surveys tab.
  2. Click on the 'Responses' tab and click on the 'Import Responses' button, which will open a dialog box.  
  3. Jump to Step 3 and select a deployment using the dropdown menu.
  4. Click on the 'upload data' button and locate and select your completed survey responses template (in .xls or .csv form).

Important notes

I1. Before importing/re-importing survey data, do not change question conditions to 'required question' in mWater after the survey is completed, or it will break the import process.
I2.With image imports, you have two options. If the image already exists in mWater and has a URL of the type https://api.mwater.co/v3/images/525e96cb226a4d56a30bfca5a23e2941, then you can just keep or add that URL in the import file, and the importer will handle that properly.
If there is no image but you want to add that, in other words, if there is text in an image question in the import file that isn't pointing to an existing mWater image, then you can select those files which should have names that match in the next step of the import process.
I3. If you just imported survey data, click on the Refresh button in your web browser to reload the page.  This will refresh the dataset list to include the one you just created.

Importing Roster Data

It's also possible to import data for any rosters in your survey. The key is to add rows under the main response row in your import, one row per roster entry. Then fill in the columns for that roster data. Each roster needs to be on its own row. So the first roster in your survey can have all of its columns on one row, but the next roster needs to have its own row, as shown below.
In this example, rows 3 and 4 add data to the roster matrix question 1 for row 2. Rows 6, 7 and 8 enter data for the first roster question for response in row 5. Rows 9 and 10 add data for the second roster question of the survey for the response in row 5.
In this example, rows 3 and 4 add data to the roster matrix question 1 for row 2. Rows 6, 7 and 8 enter data for the first roster question for response in row 5. Rows 9 and 10 add data for the second roster question of the survey for the response in row 5.

Exporting Responses

Survey data can be exported into either Microsoft Excel workbooks or CSV (Comma separated values) files.
  1. Click on the survey you want to export data from in the Surveys tab.
  2. Click on the 'Responses' tab and click on the 'Export Responses' button, which will open a dialog box.  Then select options and click on 'Export Responses'.

Formatting for re-importing

You can work on survey responses in Microsoft Excel or as a CSV file and re-import the adjusted responses into a duplicate mWater survey later.  In the same dialog box, select the 'Format for re-importing' checkbox before clicking on Exporting Responses.

Advanced exports (troubleshooting)

How to Safely Export mWater Survey Data to Excel (Without Broken Rows)
If you have complex surveys with multi-line data, and are experiencing unexpected row breaks in your exports, instead of opening the CSV directly, open Excel and import the CSV file instead. 

You can try these steps:

Step-by-Step Procedure
Step 1 — Export Data from mWater
  1. click in the home page of the mWater portal on ‘Surveys’,
  2. click on the survey you want to export data from,
  3. in the window of the survey click in the upper bar on the ‘Responses’ tab,
  4. then click in the window with survey responses on the ‘Export Responses’ button.
  5. the below ‘Export Responses’ window appears (use the settings as indicated below),
  6. click on the ‘Export Responses’ button,
Do not open the CSV file! We will do it from Excel.

Step 2 — Open a Blank Excel Workbook
Step 3 — Import the CSV File
  1. In the empty Excel file, go to the top menu: click on Data  →  From Text/CSV
  2. Select your exported CSV file (as said, it probably is in the ‘Downloads’ folder).
  3. Click Import.
Step 4 — Set the correct Import Settings
In the preview window, ensure:
Setting                              Value
File Origin                       UTF-8 (Unicode)
Delimiter                         Comma
Data Type Detection     Do NOT Detect Data Types

Now click: Transform Data
 
Step 5 — Load the Data into Excel
In the new window (Power Query):
Click: (Home)→ Close & Load
Excel will insert the data into a new worksheet.

Step 6 — Save as an Excel File
Now save the workbook: File → Save As → Excel Workbook (*.xlsx)
Give the file a name and store it.

What You Will See After Import
Excel formats the data as a table with alternating row colours (for example, light green and white rows). This is normal and helps readability. It does not change your data.

If Some Rows Are Still Broken (Important)
Sometimes 1–3% of rows may still look wrong because field staff entered:
If you see rows shifted into wrong columns, follow this fix.

Fix for Remaining Broken Rows

Step 7 — Reopen the Import (if needed)

Repeat:
Create an empty Excel file
In the Excel file: Data → From Text/CSV → Select the CSV file (probably in the ‘Downloads’ folder) → Click: Import → In the opening window, select Unicode (UTF-8). Comma, No data types selected → Click on: Transform Data. The Power Query-editor window appears with all survey data in separated columns.

Step 8 — Open the Advanced Editor
In the Power Query-editor window, click:
Home → Advanced Editor
The Advanced editor window opens.

Step 3 — Change the Quote Setting
Look for this part of the text in the Advanced editor window (usually at the end of the first line in the window): QuoteStyle=QuoteStyle.None
Change it to: QuoteStyle=QuoteStyle.Csv
Do not change anything else.
Click: Done

Step 4 — Reload the Data
In the Power Query-editor window, click: Home → Close & Load
The data will appear in the Excel file (with rows alternating in colour, blank and light green) and the rows should now align correctly.

Why This Fix Works
Some survey answers contain hidden line breaks inside one answer.

This setting tells Excel:
“If text is inside quotes, keep it in one cell even if it contains line breaks.”
Without this, Excel may split one survey into several rows.

Final Step — Save the Clean File

Always save again as:
File → Save As → Excel Workbook (.xlsx)

Use this Excel file for all analysis.

Recommended Workflow (Summary)
Every time you export from mWater:

Download CSV

Open Blank Excel

Data → From Text/CSV

Transform Data

Close & Load

Save as .xlsx

If rows look wrong:
Advanced Editor → Set QuoteStyle.Csv → Reload
Questions or working on a complex import? Please get in touch via info@mwater.co