CASE
WHEN t1.Acc_No4 IN (" ") THEN t1.Acc_No3
WHEN t1.Nmp_Subclass IN ("HRN","FRB", "HOC", "HON", "HHH") AND (t1.Acc_No3 ^? "3040820") AND (t1.Acc_No3 ^? "9040172") THEN CATS(t1.Acc_No3,"PCL")
else t1.Acc_No3
CASE
WHEN t1.Acc_No4 IN (" ") THEN t1.Acc_No3
WHEN t1.Nmp_Subclass IN ("HRN","FRB", "HOC", "HON", "HHH") AND (t1.Acc_No3 ^? "3040820") AND (t1.Acc_No3 ^? "9040172") THEN CATS(t1.Acc_No3,"PCL")
else t1.Acc_No3
Thanks Learsaas,
does it means the formula only work in one line ?
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.