Forum Discussion
Column- Max per month
- Anonymous9 years ago
Hi Sea_and_Anne,
Firstly, create a new column named yearmonth using the following formula.
yearmonth = FORMAT(Table[Date],"yyyy/mm")
Secondly, create a new column named Maxpermonth using the following formula.
Maxpermonth = CALCULATE(MAX(Table[NumberAlarms]),FILTER(Table,Table[yearmonth]=EARLIER(Table[yearmonth])))
You will get your desired result as shown in the following screenshot. For more details, please review the example in the attached PBIX file.
Thanks,
Lydia Zhang
Hi Sea_and_Anne,
Firstly, create a new column named yearmonth using the following formula.
yearmonth = FORMAT(Table[Date],"yyyy/mm")
Secondly, create a new column named Maxpermonth using the following formula.
Maxpermonth = CALCULATE(MAX(Table[NumberAlarms]),FILTER(Table,Table[yearmonth]=EARLIER(Table[yearmonth])))
You will get your desired result as shown in the following screenshot. For more details, please review the example in the attached PBIX file.
Thanks,
Lydia Zhang