Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
When I'm working with my qvw file, it occurs some abnomal data.

And I think my relevant code is all right, so I don't know where exists some issues.
Please help me! Thanks!
Best regards,
CoCo
Goto the definition of variable vOtherTotal, put '=' before the expression.
Qvd doesn't show data. Could you share sample(reduced and scrambled) app?
Related files.
Related files.
Related files.
Hi tresesco,
I've attached the relevant files. Please hava a look. Thanks.
Best regards,
CoCo
Goto the definition of variable vOtherTotal, put '=' before the expression.
Oh, Great! Thanks too much.
But the variable "vMBTotal" is also like "vOtherTotal", and the corresponding result is right. So why?

Because, in the vOtherTotal, you have two expression like Count(A)-Count(B), Ultimately if it gets expanded in the chart expression then becomes something like Exp1/Count(A)-Count(B), which is wrong, you actually need, Exp1/(count(a)-count(b)). but for vMBTotal, it is single count(), so there would not an issue if gets expanded in the chart, it would be Exp1/Count(a)... which is no different. If you put an equal sign in the variable definition, then the variable expansion would not cause the issue, because it is evaluated first. Hope it helps you understand.
Edit: for better understanding refer : http://community.qlik.com/blogs/qlikviewdesignblog/2013/11/04/the-magic-of-variables
Hi tresesco,
You explain very good. I understand. Thanks too much.
Best regards,
CoCo.