Check out the LimeSurvey source code on GitHub!
Welcome, Guest
Username: Password:

TOPIC: sumifop

sumifop 2 years 11 months ago #99051

  • MysticX
  • MysticX's Avatar
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?
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.291 seconds
Imprint                   Data Protection Statement                  Revocation information and revocation form