Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

storing multiple-choice values

  • maxfagotto
  • maxfagotto's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
11 years 1 month ago #92474 by maxfagotto
storing multiple-choice values was created by maxfagotto
I have a multiple-choice question for which the correct answer must be given 10 points, while an incorrect answer 0 points. How do I add the values ​​of these responses and save them in the database.

Thanks for the help
The topic has been locked.
  • maxfagotto
  • maxfagotto's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
11 years 1 month ago #92483 by maxfagotto
Replied by maxfagotto on topic storing multiple-choice values
More specifically I have a multiple choice question and if I answer correctly at only two of the six options provided I get a score of 10 or the score is zero.
The solution is to create a question type "numeric entry" to hide and set the default value with this formula:

{sum (if (! Q8_SQ001.value &&! Q8_SQ003.value &&! Q8_SQ005.value &&! Q8_SQ006.value Q8_SQ002.value && == 'Y' && Q8_SQ004 == 'Y', 100.0))}

Q8 is the question and SQ001, SQ002, SQ003, SQ004, SQ005, SQ006 the answers SQ002 SQ004 and are the correct ones.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose