This content has been marked as final. Show 3 replies
I'm here with some issue in set analysis.
Imagine I want the following table.
To calculate the distinct count of customer with Status='Y' based on the latest date of each customer only. Based on the data above, my expected result should be 2.
My set analysis, which is wrong somewhere :
count(Aggr(max(If(TXN_DT_ID = FirstSortedValue(TOTAL <CUST_ID> TXN_DT_ID), if(STATUS='Y',CUST_ID))), CUST_ID))
Anyone can help on the set analysis?
Thanks in advance.