Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Laura_May
Frequent Visitor

Filter a table visualisation using a bar chart

I have a table visualisation that looks similar to the below, where records with errors have a value of 1.

Record ID

Error

1234

1

1235

 

1236

1

 

I have a bar chart that contains the error field as a count. I want to be able to click on the bar and then only show the rows with errors in the table. I have tried using edit interactions and selecting filter, but this doesn’t change anything. Am I missing anything?

1 ACCEPTED SOLUTION

Alright then, I believe what you would need to do is to put the error field on the "legend" well of the bar chart, and select the error field you want on the legend:

dlopesc04_0-1730121094204.png

Versus just selcting the column:

dlopesc04_1-1730121123350.png

Othen than this I got nothing, would be interested to know if anyone has a workaround where selecting the column highlights all the values, not just the "row" it belongs to.

 

View solution in original post

6 REPLIES 6
Anonymous
Not applicable

Hello,dlopesc04 ,thanks for your concern about this issue.

Your answer is excellent!
And I would like to share some additional solutions below.
Hi,@Laura_May .I am glad to help you.
like this?
When the toolbar is clicked, all rows with [Error] column = 1 are displayed in the table.

vjtianmsft_0-1730185557294.png

When I click on the Error column in the first bar, only Record IDs 1234 and 1236 are shown in the table on the left (they correspond to the value Error)

vjtianmsft_1-1730185585111.png

And when I click on the bar below, I can realize highlighting (when I click on the bar Record ID=1234 data), the left table is equivalent to the Record ID=1234 filtered, only display Record ID =1234 data rows!


Both of the above cases are actually cross-filtering and highlighting effects between different visuals.
URL:
Understand how visuals interact in a report - Power BI | Microsoft Learn

vjtianmsft_2-1730185629164.png

If you want to realize the effect of the first one, you can refer to my test below
1. Creating a measure that displays part of the null value as a marker.
For some value=blank data rows in power BI, power bi will ignore them by default and not display them when they are aggregated in visual (because the value is empty, and there is no point in aggregating the empty values), it is better to create an auxiliary measure, modify its empty values, and display them in visual.

vjtianmsft_3-1730185655402.png

The measure specifies that if the value is null, it is assigned to an empty string, which will successfully allow Record ID = 1235 data in the [Error] column aggregation is also displayed (measure defaults to the state of aggregation, the result is a scalar value)

2. Create a grouped calculated column
In order to display all rows of data with an error column status of 1 together in the table, you need to group all the data with an error column = 1 into one group (create a calculated column that acts as a marker for the columns that need to be physically present, and place them in the sort axis)
Like this:

vjtianmsft_4-1730185706013.png

3. Create a separate tool bar chart that triggers cross-screening of all Error = 1 data in the table.

vjtianmsft_5-1730185730449.png

4. To achieve the effect: the system automatically determines the classification axis has a hierarchical structure, you click on the first level (IF Error), at this time all Error = 1 data will be cross-screened out!
Like this:

vjtianmsft_7-1730185795236.png


I have also shared the pbix file of my test, I hope my test is helpful to you.


I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Carson Jian,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

dlopesc04
Resolver II
Resolver II

It is difficult to say for sure without taking a look at your model. What fields are on the bar chart? If they are from different tables is there a relationship between them?

The bar chart just contains the error field as an implicit measure. This is the same field as the error column on the table visualisation. 

Alright then, I believe what you would need to do is to put the error field on the "legend" well of the bar chart, and select the error field you want on the legend:

dlopesc04_0-1730121094204.png

Versus just selcting the column:

dlopesc04_1-1730121123350.png

Othen than this I got nothing, would be interested to know if anyone has a workaround where selecting the column highlights all the values, not just the "row" it belongs to.

 

Thank you - this works. I now have more than 1 error column. Is there a way of achieving this with multiple fields? I can only add one field to the legend.

@Laura_May  You should structure you table so that any other values you would like to be shown in this legend are also on the "error" column, if you're not too familiar with that this link may help you:
https://medium.com/@cherifal2011/normalization-and-denormalization-in-power-bi-295d4dfbf3ab

Basically you should only have one error column, and will probably have to pivot/unpivot your data in Power Query at some point; Same data point has two or more errors? Two rows on the table, one for each error ID, and you have a dimensional table containing all the Record IDs related to you fact table, and that is the field you'll use in any visual.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors