Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am really confused to use aggr function as am not clear reg. the difference between
sum(Aggr(Total_Payment), ID)
and
sum(Aggr(max(total_payment), ID))
Please help me understanding the difference.
Thanks,
Rohini. M
First one is simple Aggregation which values from ID based on Total_Payment
Second one is Only get which is the Maximum value from Total_Payment which Calc part should ID
OR
Check by your hand using this
1) Sum({<total_payment=>}ID)
2) Sum({<total_payment= {"$(=Max(total_payment))"}>}ID)
sum(Aggr(Total_Payment), ID) - Using aggr() without any aggregation function inside doesn't make much of sense.
sum(Aggr(max(total_payment), ID)) - This gives you sum of all the max values of Total_Payment against each IDs.
To understand such expression, best to create a sample and try to understand the output.