Forum Discussion
E_Rye
6 months agoFrequent Visitor
Can rows be hidden from a Table visual without removing the rows from a measure shown in the Table?
Hello, Is there a way to filter/hide rows in a Power BI table visual and keep the associated measure counts for those rows? My table below summarizes a 36 month lookback for IDs which have a li...
- 6 months ago
I have found the solution is to create a visibility flag measure to identify the rows that are within 24 months of the current date, as below, and then use that measure as a filter on the visual. For some reason the visibility flag measure does not working for 'Filters on this page' but does work for 'Filters on this visual'.
Within24Months (measure) =VAR CurrentDate = TODAY()VAR RowDate = MAX('Date'[Date])VAR MonthDifference = DATEDIFF(RowDate, CurrentDate, MONTH)RETURNIF(MonthDifference >= 0 && MonthDifference <= 24, 1, 0)
E_Rye
6 months agoFrequent Visitor
I have found the solution is to create a visibility flag measure to identify the rows that are within 24 months of the current date, as below, and then use that measure as a filter on the visual. For some reason the visibility flag measure does not working for 'Filters on this page' but does work for 'Filters on this visual'.
Within24Months (measure) =
VAR CurrentDate = TODAY()
VAR RowDate = MAX('Date'[Date])
VAR MonthDifference = DATEDIFF(RowDate, CurrentDate, MONTH)
RETURN
IF(MonthDifference >= 0 && MonthDifference <= 24, 1, 0)