Hi. I am trying to create a calculated column step in T&C where I can use the result of a case statement as a subquery. I was thinking that I can either set a temp variable or assign it a name as below. Not sure about syntax. The error I keep getting is the missing keyword. Thanks!
The version I am using is 18.104.22.168
CASE WHEN (AID_TYPE='X') THEN
(CASE WHEN (ITEM_TYPE ='1' OR
ITEM_TYPE IN ('120', '220')) THEN '2'
WHEN ITEM_TYPE IN ('120') OR
ITEM_TYPE IN ('240','247') THEN '3'
ELSE '4' END) AS Y