Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Qlik Certification Exam Sale - 40% off. Register by June 30, 2020. GET DETAILS
Contributor II

IF Condition

Hello Qlik Folks,

I have 2 expression some thing like below 

if(isnull(OldPrize),(sum(GROSS_SALES)/sum(SHIPPED_QUANTITY)),OldPrize)---Old Gross Price / Unit - this is working fine 

if(isnull(AdjSale),(sum([Adj Sales])/sum(SHIPPED_QUANTITY)),AdjSale)----Old Adj Sales/Unit- Not Working 

the only diff I see in both expressions GROSS_SALES vs [Adj Sales], GROSS_SALES  is coming from data, [Adj Sales] is an other expression contains multiple other expressions.

[Adj Sales] defined as: [Gross Sales] - (Royalties + [PA - Acc] + [PA - UnAcc] + [Unplanned Allowances])

which is 

clipboard_image_0.png

when I elaborate it is throwing error in expression please help me to write this in proper format?

 

Tanks,

D

1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Re: IF Condition

Did you notice that the error is actually coming from double commas?

clipboard_image_0.png

 

View solution in original post

2 Replies
Highlighted
Partner
Partner

Re: IF Condition

Did you notice that the error is actually coming from double commas?

clipboard_image_0.png

 

View solution in original post

Highlighted
Digital Support
Digital Support

Re: IF Condition

D, did Arthur's post catch the issue?  If so, please do not forget to use the Accept as Solution button on his post to mark that as the solution and give him credit. 

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.