Question type: Single question

From Catglobe Wiki
Jump to: navigation, search



Question type: Single question

Question type: Single question

Type

Number

General Description

This is the most common question type where there is a text and some answer options of which you can choose only one. Each answer option is represented by a number; typically starting from 1 and increasing by 1 for each option thereafter.

A typical single question would be ‘What is you gender?’ with answer options ‘Male’ (represented by a 1 on database) and ‘Female’ (represented by a 2 on database). An answer could e.g. be ‘1’ (meaning the user is a man).

Single questions may also have open parts; that is an option which requires you to specify some additional text for the chosen option. An example of this could be ‘In which country were you born?’ with answer options ‘USA’ (=1), ‘Denmark’ (=2), ‘Other, please specify’ (=3). Let us imagine that the 3rd answer option is an partly open option, meaning that the user after having chosen it must write the exact country in which he was born. In order to import these half-open options the user will need to place half open answers in a separate column in the imported excel.

Import Group

Import Data (by selecting a questionnaire)

Business Rules

  • The name of the question to which you wish to import data must be the same as the imported files column header in order to ensure auto-mapping.
  • Value in excel column must not be outside the range of possible answer option values on database (in the first of the above examples, any value besides 1 and 2 would be an error). A null is also allowed and shows that the user did not answer the question.
  • If options of the question have open parts, each open part will be split to one column that can be mapped to during import. These columns work in the same way as text questions. If we try to import an open part of an answer option that is not selected, the open part will be ignored. In order to automatically map semi-open questions we need to name the excel column the same name as the Single Question + ‘_AO_’ + ‘n’, where n is the option number. In the example above, where label was ‘Country’ and the option with an open property was option 3, the name of the column in excel would need to be ‘Country_AO_3’. Here is an example of a file where we import to a question named "country" where option 3 has an open property.
    868.gif

 

Validation

  • Number must be a whole integer number from 0 and up. If strings or illegal characters are found in a column an error will be given during validation. Error type: ERROR (the import job will not be allowed to be executed).
  • If value is outside the range of possible answer option values on database an error message will be shown. Error type: ERROR and you cannot finish the import job.
  • We will only be allowed to import open parts of questions to answer options that do exist, i.e. even though a the open property of a single question has option 9 set as open then such an import will not be offered if there is no option 9 for the question.

Notes

A number of situations can happen when you import open and closed question parts and these are not logically related for a specific user

Situation 1: When importing only closed parts

  • Any open parts will be set to null.

Situation 2: When importing both open and closed parts

  • If the two are not logically related then the open part will not be imported.

Situation 3: When importing only open part

  • If open part does not fit with current closed parts then open part is ignored.
  • If closed part is null then closed part will be set to selected and open part then imported.