Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Expression help please

    IDTYPEAMOUNT
1RENT400
1RENT200
1DEP300
1DEP300
2TAX100
2TAX200
2RENT400
2RENT100
For each ID I have to get the max of amount of each type and then sum it..
Here Ex: ID =1 ,Max(Rent) =400
Max(Dep)= 300
For ID =1,Amount is 700

Thank you very much .

11 Replies
sunny_talwar

May be this:

Sum(

          If([Expense Month-Year] >= date(Today(),'MMM-YYYY'),

               If([Expense Month-Year] <= date(AddMonths(Today(),12),'MMM-YYYY'),

               Aggr(

                    (Max([Amount of Expense]) * Pick(Match(pay_frequency, 'MONTHLY', 'QUARTERLY', 'ANNUALLY', 'SEMI-ANNUALLY'), 12, 4, 1, 2)),%SubspaceKey,[Expense Type]))))

Not applicable
Author

Thank you very much...it made wonders