Qlik Community

Qlik Connectors Discussions

Discussion Board for collaboration regarding Qlik Connectors.

ramkumar_manick
New Contributor III

Variable Expression for SUM

I am trying to do bar chart with some selected month data QTY sum value only to display, so i planned to create Variable as expression to get input for Selected month. but it is not working...

Variable:

Variable Name: v2017Jun

Expression Formula: [Calendar Month-Year - RD]= {'Jan-2017','Feb-2017','Mar-2017','Apr-2017','May-2017','Jun-2017'

Expression formula i used in chart is..

=(Sum({$<v2017JUN>}[RW Qty]))

If i used this expression, chart accumulating all month RW QTY sum values, not which i selected month which i need...

If is fixed the variable, so i can use it at multiple chart for selected month, also i will add or delete some month in future too...

can any one help on this...

1 Solution

Accepted Solutions
MVP
MVP

Re: Variable Expression for SUM

This isn't really a Qlik Web Connectors question, so you may be better off moving the conversation to another forum.

However... Your variable code appears to be missing a closing }.

Where you refer to the variable you are missing the dollar sign expansion, it should read:

=(Sum({$<$(v2017Jun)>}[RW Qty]))

Also, be careful as variables are case sensitive.

It's always a very good idea to ensure that your expressions are working well before you move things into variables, and then replace bits a little bit at a time - then you know which change (if any) breaks your expression.

Hope that helps.

Steve

4 Replies
MVP
MVP

Re: Variable Expression for SUM

This isn't really a Qlik Web Connectors question, so you may be better off moving the conversation to another forum.

However... Your variable code appears to be missing a closing }.

Where you refer to the variable you are missing the dollar sign expansion, it should read:

=(Sum({$<$(v2017Jun)>}[RW Qty]))

Also, be careful as variables are case sensitive.

It's always a very good idea to ensure that your expressions are working well before you move things into variables, and then replace bits a little bit at a time - then you know which change (if any) breaks your expression.

Hope that helps.

Steve

ramkumar_manick
New Contributor III

Re: Variable Expression for SUM

Thanks Steve.... Its Working now......

oknotsen
Honored Contributor III

Re: Variable Expression for SUM

If your question is now answered, please flag the Correct Answer (via the big "Correct Answer" button near every post; not visible in preview) and Helpful Answers (found under the Actions menu under every post).

If not, please make clear what part of this topic you still need help with .

May you live in interesting times!
MVP
MVP

Re: Variable Expression for SUM

Excellent.  Thanks for letting me know that worked for you.

Community Browser