Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
ferha_jafri
Partner - Creator III
Partner - Creator III

not able to add two set analysis expression

Hello Everyone,

I have an issue as i am not able to add two set analysis expression for one dimension eg.

sum({<year={2003}>}sales)+sum({<year={2004}sales>})

1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

try

SUM({<Year = {'2003','2004'}>}sales)

View solution in original post

11 Replies
MK_QSL
MVP
MVP

try

SUM({<Year = {'2003','2004'}>}sales)

Not applicable

Sum({<Year={'2003','2004'}>}Sales)

Not applicable

Hello,

There is a error in your formula, try this :

sum({<year={2003}>}sales)+sum({<year={2004}>} sales)

But if you want a set analysis with several values for the same dimension, you should write this :

sum({<year={2003, 2004}>}sales)

fdelacal
Specialist
Specialist

you can do it that.

sum({<year={'2003','2004'}>}sales)

senpradip007
Specialist III
Specialist III

Hi Ferha,

Your expression is wrong. The Correct one is as follows:

Sum({$<Year={'2003'}>} sales) + Sum({$<Year={'2004'}>} sales)

But as you are using set analysis, you must use like

Sum({$<Year={'2003','2004'}>} sales) which is more authentic.

Not applicable

Dear Sir/Madam,

Thank you for your E-mail. We may or may not have received your mail. Please forward the same mail to my new mail id hitesh.makwana@goapl.com again.

Kindly update your address book for future communications.

Rgds,

Hitesh Makwana

022, 42187749

ferha_jafri
Partner - Creator III
Partner - Creator III
Author

the exact expression is

if([Brand Description]='AERRANE (ISOLFURANE 250 ML)', if(Currency='INR',

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9101'}>}[Net Sales Amt]),

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9101'}>}[Net Sales Amt]/$(vConversionRate)))/1000,

if([Brand Description]='ISOFLURANE USP 100ML', if(Currency='INR',

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9100'}>}[Net Sales Amt]),

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9100'}>}[Net Sales Amt]/$(vConversionRate)))/1000,

if([Brand Description]='ISOFLURANE-100ML',(if(Currency='INR',

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9101'}>}[Net Sales Amt]),

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9101'}>}[Net Sales Amt]/$(vConversionRate)))/1000

+if(Currency='INR',

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9100'}>}[Net Sales Amt]),

SUM({<YearMonth={$(vCurrentYearMonth)},[Invoice Date]={'<=$(vCYTDDate)'},Zone={'India','North','South'},[Product Code]={'IN2L9100'}>}[Net Sales Amt]/$(vConversionRate)))/1000))))

and i am not able to get the sum.

Not applicable

Dear Sir/Madam,

Thank you for your E-mail. We may or may not have received your mail. Please forward the same mail to my new mail id hitesh.makwana@goapl.com again.

Kindly update your address book for future communications.

Rgds,

Hitesh Makwana

022, 42187749

MK_QSL
MVP
MVP

Try like this <=$(=vCYTDDate)