• MysticX
  • MysticX's Avatar Topic Author
  • Visitor
  • Visitor
5 years 2 months ago #99051 by MysticX
MysticX created the topic: sumifop
Hi everyone!

I'm trying to setup a question group of radio list questions. Possible answers code range from 1 to 4, with a special answer code set to 998.

I would like to have an equation question that computes the sum of the questions codes that are not equal to the special code (998), and displays that at the end of the question group. So I have an equation question that is not shown, and then a text boilerplate that displays the hidden equation result.

Now, when I try to use the sumifop (which seems to be the appropriate expression to use) that way:


with t3_sssa* being the questions codes I need to add up, I get a string result instead of a numerical result...

More specifically, let's say that the code for t3_sssa1=1, t3_sssa2=3 and t3_sssa2=998 (ignoring the others for now). The result that is displayed in the boilerplate question is 013 instead of the result that should be 4...

If I only use a sum expression, the correct result is displayed in the boilerplate question (in that case, that would be 1002, since the 998 code would be added up).

Any idea of what's happening there?

Please Log in or Create an account to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!