Actions

Import responses

From LimeSurvey Manual

Revision as of 16:37, 7 February 2019 by Cdorin (talk | contribs)
  Under construction




Once your survey is active you can start browsing responses and export them for further analysis. To access the export function, select Responses & statistics from the main toolbar (displayed on any survey-related panel) and then click on Responses:



The default page, Response summary will be loaded. Now, look for the Export option located on the top top toolbar:



Several options are available:

  • Import responses|Import responses from a deactivated survey table|Import responses from a deactivated survey table]]
  • Import responses|Import a VV survey file|Import a VV survey file]]


Import

Import responses from a deactivated survey table


As long as the first two lines are intact, you can then import the data in your vv survey file back into an active LimeSurvey survey.

If you used Microsoft Excel to edit the exported vv file, the data structure of this file may be corrupted, so LimeSurvey is not able to import the edited file. You can try the following workaround to get the import working without an error:

  • Open your exported vv file in Excel and do your changes (I guess you already did that)
  • Save it as tab-separated text file (It creates a new file with the extension .txt)
  • Do another "clean" vv export from LimeSurvey
  • Open this new exported vv file with a texteditor like notepad or something else (I used textwrangler on mac)
  • Press CTRL + A to mark all of the content and delete it
  • Open the Excel edited vv file (the tab separated .txt file) with a texteditor and press CTRL + A to mark all of the content
  • Press CTRL + C to copy the content and paste it into the new (now empty) vv file
  • Press CTRL + S to save the file as it is (as .csv)
  • Now try to import this file

Then, from the browse screen, choose the "Import a VV Survey file" icon.

The "Import a VV Survey File" screen needs you to choose the "vvexport" file you are importing. If you choose to "Exclude Record IDs" the records will be imported and brand new Record ID's will be generated for them (use this option for the use case "Adding new responses to the existing responses of a survey"). If you un-check this box, then the original record id's will be imported (use this option for the use case "Overwriting all responses of the survey").

There are a range of options you can choose that tell LimeSurvey how to deal with double or multiple entries.

  • Report an error (and skip the new record).
  • Renumber the new record
  • Replace the existing record (uses this for the use case "Overwriting all responses of the survey")


Importing a VV survey file

File:VV2-import-en.png
  • File : Select the file to be uploaded. The file must be a TSV file: A text file with each column separated by TAB.
  • Exclude record IDs? : If 'id' column exist in the file you can exclude this line or not. If this setting is checked then a new record is added for each line of the .vv file. If unchecked you can choose:
  • When an imported record matches an existing record ID:
    • skip : Report and skip the new record. After upload you will see if the record already existed - if it existed it's not imported.
    • renumber : Renumber the new record. A new record is added to the response table with answer of the VV file.
    • replace : Replace the existing record. The old record is deleted and completely replaced by the record from the VV file
    • replaceanswer : Replace response details from the file in the existing record. The old record is updated with the new response from the VV file. This allow to replace only one question in the response table.
  • Import as not finalized response? : If checked the submitdate is set to NULL, so the response is set to not completed.
  • Character set of the file : You can choose the character set of the file - the default and recommended value is UTF-8 but some spreadsheet program don't allow to choose a character set.
  • First line contains question codes : By default VV file first line contain human readable question, the real column names are in the second line. This allow to use the first line as the real column names.
  • Force import : If the question codes are not found in the database name or in Qcode Variable Naming then columns are assigned depending of order. This can be used to import VV file from different LimeSurvey instance but each survey must be exactly the same. We strongly recommend to use this only if you know what you are doing. It can be very dangerous and lead to results ending up in the wrong column.