Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content
Announcements
Qlik Insider: Product Roadmap Edition on March 3, 1 PM ET: REGISTER TODAY
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

set analysis error

Hi,

i have an issue with set expression the following is expression

if(Desc2='Gross Profit',(sum({<vc_gl_code_L1={'4'} , YEAR={$(VMaxYear)}>} DEBITAMT-CRDTAMNT)*Flag_Sales

-

(sum({<vc_gl_code_L1={5},YEAR={$(VMaxYear)}>}DEBITAMT-CRDTAMNT))

the above expression it displaying only first expression  value that means after '-' operator expression  value is not considering.

1 Solution

Accepted Solutions
Not applicable
Author

Thanks to all

if(Desc2='Gross Profit',(sum({<vc_gl_code_L1={'4'} , YEAR={$(VMaxYear)}>} DEBITAMT-CRDTAMNT)*Flag_Sales

-

(sum({<vc_gl_code_L1={5},YEAR={$(VMaxYear)}>}DEBITAMT-CRDTAMNT)) it is correct but am using variable of this expression

View solution in original post

4 Replies
Anonymous
Not applicable
Author

Braces are incorrect. CAn you please explain what you are trying to here??

tresesco
MVP
MVP

May be you need to add one more parenthesis like.

if(Desc2='Gross Profit',(sum({<vc_gl_code_L1={'4'} , YEAR={$(VMaxYear)}>} DEBITAMT-CRDTAMNT)*Flag_Sales

-

(sum({<vc_gl_code_L1={5},YEAR={$(VMaxYear)}>}DEBITAMT-CRDTAMNT)) )

Anil_Babu_Samineni

May be parenthesis missing on end

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Not applicable
Author

Thanks to all

if(Desc2='Gross Profit',(sum({<vc_gl_code_L1={'4'} , YEAR={$(VMaxYear)}>} DEBITAMT-CRDTAMNT)*Flag_Sales

-

(sum({<vc_gl_code_L1={5},YEAR={$(VMaxYear)}>}DEBITAMT-CRDTAMNT)) it is correct but am using variable of this expression