March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
How can I create a measure that reflects visual level filters that are set in the filter pane in the section 'Filters on this visual'?
Having one table with 3 rows:
table1.column1
1
2
3
Putting this in a table visual and setting the visual level filter for column1 to < 3 (Filter Pane: Filters on this Visual) I would like a measure to show the number of rows shown in the visual (= two rows!).
measure = COUNTROWS( table1 ) >> returns 3
measure = COUNTROWS( ALLSELECTED( table1 ) ) >> returns 3
measure = COUNTROWS( ALL( table1 ) ) >> returns 3
I can use the page-level filter in the filter pane of course - but I would like to know how this can be done when using the visual level filter pane!
Thanks!
Solved! Go to Solution.
Incase if you want to put your column in one table visual and measure on a different visual then, AFAIK then you will not be able to get your desired output. Because visual level filters on one visual will not propagate to other visuals. Either you need to use page level or report level filters to create a filters pane.
Then you will be able to capture all the filters on your report. Here is an intresting article about DUMPFilters by SQL BI team: https://www.sqlbi.com/articles/displaying-filter-context-in-power-bi-tooltips/
Incase if you want to put your column in one table visual and measure on a different visual then, AFAIK then you will not be able to get your desired output. Because visual level filters on one visual will not propagate to other visuals. Either you need to use page level or report level filters to create a filters pane.
Then you will be able to capture all the filters on your report. Here is an intresting article about DUMPFilters by SQL BI team: https://www.sqlbi.com/articles/displaying-filter-context-in-power-bi-tooltips/
@tharunkumarRTK thanks! Very interesting indeed! The solution is easy of course - like you said just use the page level filters. However still interesting that there is no easy solution to this!
@chris__1 Try:
Measure = COUNTROWS(ALLSELECTED('Table'[Column1]))
See attached PBIX file.
thanks @Greg_Deckler for your answer!
It seems I can't upload a pbix file - but here is a screenshot of the file you created.
I would like to have a measure that displays the current row count (with visual level filter set in the filter pane): it shows "3" and I would like it to show "2":
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
124 | |
82 | |
69 | |
53 | |
44 |
User | Count |
---|---|
202 | |
106 | |
100 | |
64 | |
56 |