Monthly Archives: March 2014

Question Import Formats in WatuPRO

The old import format was often causing confusion so from version 4.2.3 we switched to three much better formats. Don’t worry, the old formats will still be supported for some time through the “Legacy import/export” link.

The new formats supported by WatuPRO are currently these:

Simple Import (CSV):

Download sample file: import-simple. (right-click and choose “Save as”. Note: the file is COMMA delimited.) For versions before 6.4.9.5 use this file: import-simple-old.csv

Do not use this format when importing files exported by the plugin. Use “Advanced WatuPRO” instead.

This is a simple CSV file that has only two columns with question properties:

  • Question contents
  • Question type – radio, checkbox, textarea (all small letters)
  • Is required? (enter 0 for not required and 1 for required). From WatuPRO version 6.4.9.5.
  • Optional answer explanation From WatuPRO version 6.4.9.5.

Then the answers follow in unlimited sets of 3 columns in this order:

  • Answer contents
  • Is correct? (Enter “0” for wrong answer and “1” for correct answer)
  • Points assigned

You can import “fill the gaps” and sorting questions with this import format but you will not be able to import many of the properties. So this import format is best suited for single-answer, multiple-answer, and open-end questions.

Advanced Import (CSV)

Download sample file:  import-advanced (right-click and choose “Save as”. Note: the file is COMMA delimited.)

WatuPRO exports files in this format. Use it always when importing questions exported from other WatuPRO quiz.

This format contains all the question properties in columns and is a subject to change if a new property gets added to the questions. This is also the format that is exported by WatuPRO so at any time you can get the most actual format by simply exporting some of your questions.

All columns must be present in your CSV file but you can leave empty most of them. So feel free to enter only the properties you need.

Aiken format

Download sample file: import-aiken (right-click and choose “Save as”)

We now support the easy and simple Moodle’s Aiken format. Learn more about it here.

Please note Aiken should be followed EXACTLY. Each answer should have a letter like A, B, C, etc and then a point or brace. Example: A. or A). Each answer should be on its own line and cannot take more than one line.

The right answer should on the next line after the last possible answer and should have “ANSWER:” written before it, exactly as you see it: all caps and a colon. Example:

ANSWER: C

Whole question example:

What is the correct answer to this question?
A. Is it this one?
B. Maybe this answer?
C. Possibly this one?
D. Must be this one!
ANSWER: D

Enhancements to Aiken

From version 6.3.2.5 we have built our own enhancements to the Aiken format that allow you to pass question category and answer explanation. Note that they are not part of the official Aiken format and can be used only in WatuPRO.

To add a question category enter a line starting with CATEGORY:, then follows the category name.

To add answer explanation enter a line starting with EXPLANATION:, then follows the answer explanation. It should be all on one line – if your explanation needs multiple lines, use the HTML tags for paragraphs and new lines but do not hit the enter key on your keyboard.

Both “CATEGORY:” and “EXPLANATION:” lines should be entered before the “ANSWER:” line and should be in all caps and with a semicolon – exactly as you see them. Entering the lines is optional – you can skip any or both of them on any or all questions. When importing such questions just select the “Aiken” format – WatuPRO will figure out the enhanced questions on its own.

For a sample import file, check this one:  watupro-aiken (right-click and choose “Save as”)

Moodle XML

From version 6.6.4.5 WatuPRO has a partial support for the Moodle XML format. This format is very complex so we have added only some basic functionality but it’s a good start. We will be implementing it gradually if there is interest.

For a sample Moodle XML click here or right-click and choose “Save as”.

Currently supported:

  • Moodle’s “multichoice” question type which converts into our single-choice and multiple-choice questions/
  • If there are images and the links to them are accessible, they will be automatically copied to your WatuPRO installation.
  • The feedback fields, randomization settings, hidden are not (yet) supported.

Troubleshooting

The import functions are tested literally thousand times on multiple systems. No exaggeration. They work fine.

So before sending us support emails please double and triple check the following:

a) The import format. If you are trying to import advanced file format as “Simple WatuPRO” it will not work correctly. You will get 0 and 1 as answers to questions, and many other misplaced fields. So please even if you are sure your file is “simple” do try the Advanced WatuPRO format. I can’t count the times when people just didn’t try it and asked us why import didn’t work. This wastes a lot of time for both you and us. It takes a minute to try the other format so why not do it?

b) The field delimiter. Most CSV files are comma-delimited (this is where the name comes from). Our demo files listed here are comma-delimited. That’s why comma is selected by default. This does not mean all files are comma delimited. Maybe someone gave you a file that is tab-delimited. Or maybe your Excel is configured to export semicolon delimited files. You can usually figure out the proper delimiter when you try to open the file in Excel or Libre Office calc. But if you can’t: if your import is wrong, just try the other field delimiters.

c) The foreign characters checkbox. It is under the Skip title row checkbox:

Normally it should not be checked. Do not check it unless you have tried the different formats and field delimiters.

d) Your file is in non-Unicode format.

WordPress database is in Unicode, UTF-8 format. Your files should be as well. If you are having problems with partly imported or not imported at all questions, skipped questions, etc, it’s almost guaranteed that your file is non-unicode. Please follow this guide to save it as unicode file. As a final resort you can send your file to us and we will convert it as long as we can figure out the original encoding.

Please note the above 4 trouble points. They will save you the time to wait for answer to your email. Trying the different options takes a minute or two at most.

e) A new column has been added

Sometimes we have to add new columns to the import/export files to add new question properties. In such cases files exported with old versions will not work without modification.

If you are using a file which has been exported with an older WatuPRO version you may run into such an issue. It’s very easy to check if this is the problem: export a new file from some of your quizzes and import it. If it works, then the problem is most likely that the new import format has more columns than your previously exported file.

The easiest solution is to re-export. In the case when you have already worked on the file and want to use it, you need to add empty columns in your file at the place of the new columns in the newly exported file. We always add these columns right before the first answer of the question so it’s relatively easy to compare both files and check how many columns you need to add.