on 01-21-2015 4:38 AM
Dear Experts,
I have following requirements that will use IN operators.
the column A have these values (COIN, KOVO,RKU1, COIE......) and Column B have these values (A, S, H, L) now if column "A" IN ('COIN', 'RKU1','COIE') AND Column B NOT IN ('A','L') Then 'S' elseif Column B IN ('A','L') then 'H' else Column B.
so I have tried to use the below syntax in HANA
If("A" IN ('COIN','RKU1','COIE') AND "B" NOT IN ('A','L'),'S',if("B" IN ('A','L'),'H',"B"))
but it wont validate says invalid expression, so we can't use IN operators in Calculated column? or how I will achieve this logic?
Please advise.
Thanks,
Karuppiah N
Hi Karuppaih,
Your syntax is not proper. It takes as in("attr",[values]). So your logic will look like this.
If(IN ("A",'COIN','RKU1','COIE') AND NOT IN ("B",'A','L'),'S',if(IN ("B",'A','L'),'H',"B"))
Let me know if your still facing the issue.
Regards,
Safiyu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.