Forum Discussion
Fusion_Tomo
Advocate I
3 years agoCount instances only if categorised the same for previous 3 months
Hey guys, I have the following fact table that records mobile phone billings as at the last day of each month: The table is connected to a Calendar table and a Mobile Service dim table that c...
Shaurya
Memorable Member
3 years agoHi Fusion_Tomo,
You can use the following DAX Formula:
Category = IF(CALCULATE(DISTINCTCOUNT('Table'[Data Usage Category],FILTER(DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-3,MONTH)))=1
&& 'Table'[Data Usage Category]<>"Nominal",
MAX('Table'[Data Usage Category]),
"Nominal")
Works for you? Mark this post as a solution if it does!
Consider taking a look at my blog: How to Export Telemetry Data from Azure IoT Central into Power BI
Fusion_Tomo
Advocate I
3 years agoThank you for taking the time to respond but that doesn't work - Power BI will not allow me to enter the 'Table'[Data Usage Category]<>"Nominal" condition and I'm not sure the logic of the formula is suited to the problem.