Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
How do we use and operator in if condition.
for eg.
if we need to represent account between 1 million and 5 million, so do we do that?
in Expression
=if(account >1000000 and account <5000000, THEN , ELSE)
in Script
if(account >1000000 and account <5000000, THEN , ELSE) as Field,
Regards
tim
I need to use and in above condition for middle account along with aggregate and sum function.
seems like you should use it like this:
aggr(sum(if(middle_account>1000000 and middle_account<5000000, middle_account)), YourDimension)
=if(Aggr(sum(Revenue),[Customer Group Descr])<1,'Tail Account',
if(Aggr(sum(Revenue),[Customer Group Descr])>1 and Aggr(sum(Revenue),[Customer Group Descr])<5,'Middle Account',
if(Aggr(sum(Revenue),[Customer Group Descr])>=5,'Large Account'))
I m getting error in this expression
what is wrong with it?
do you really Need the aggr() function at this Point?
if you have Customer Group Descr as Dimension you can use this expression:
if(sum(Revenue) < 1,'Tail Account',
if(sum(Revenue)>1 and sum(Revenue) <5,'Middle Account',
if(sum(Revenue)>=5,'Large Account')))
Yes, as I need to group by customer group descry.
This AND is not working fine.
I m getting invalid dimension error.
can you share a sample qvw?