Forum Discussion
Create a cumulative count based on criteria
- Anonymous3 years ago
Hi AragakiSora ,
Please check that this calculated column meets your requirements:Flag = VAR CurrentName = 'Table'[Name] VAR CurrentDate = 'Table'[Last Update] VAR CurrentID = 'Table'[ID] VAR MinDateWithID = CALCULATE( MIN('Table'[Last Update]), FILTER( 'Table', 'Table'[Name] = CurrentName && NOT(ISBLANK('Table'[ID])) && 'Table'[Last Update] <= CurrentDate ) ) RETURN IF( ISBLANK(CurrentID) && MinDateWithID > DATEADD('Table'[Last Update], -7, DAY), 1, 0 )Best Regards,
Gao
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
AragakiSora , with help from date table, create measure like
M1 = calculate(countrows(filter(Table, isblank(Table[ID]))),filter(all('Date'),'Date'[date] <=max('Date'[date])))
M2 = calculate(countrows(Table),filter(all('Date'),'Date'[date] <=max('Date'[date])))
Blank only count = Countx(values(Table[Name]), if([M1] = [M2], [Name], Blank()))
Power BI Window function Rolling, Cumulative/Running Total, WTD, MTD, QTD, YTD, FYTD: https://youtu.be/nxc_IWl-tTc
https://medium.com/@amitchandak/power-bi-window-function-3d98a5b0e07f
Running Total/ Cumulative:
https://www.youtube.com/watch?v=h2wsO332LUo&list=PLPaNVDMhUXGaaqV92SBD5X2hk3TMNlHhb&index=42