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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
hollyse
New Member

Filter on just one column of column chart

On column chart, is there a way to have filters on just a specific column? I'm adding 3 columns, active, updated 5+ Days ago, and Open 30+ Days. I want them to be independent of each other, unless there is a better way i can show which of the active ones are also 30+ Days old and/or haven't been updated for 5+Days...it seems as if when i change settings of one column though, it is also messing with one of the other columns...

1 ACCEPTED SOLUTION
v-xinruzhu-msft
Community Support
Community Support

Hi,

Thanks for the solution ryan_mayu  offered, and i want to offer some more infotmation for user to refer to.

hello @hollyse , you can refer to the following sample.

Sample data 

vxinruzhumsft_0-1734664507905.png

1.Unpivot the data to the following.

vxinruzhumsft_1-1734664551087.png

2.Create the following tables, there are no relationships among the tables.

True/Fales table

vxinruzhumsft_2-1734664583919.png

 

Type table

vxinruzhumsft_3-1734664600724.png

Then create the following measure.

 

MEASURE =
IF (
    ISFILTERED ( 'Type'[Attribute] ) && ISFILTERED ( 'True/False'[Value] ),
    IF (
        SELECTEDVALUE ( 'Table'[Attribute] ) IN VALUES ( 'Type'[Attribute] ),
        CALCULATE (
            COUNTROWS ( 'Table' ),
            FILTER (
                'Table',
                'Table'[Attribute]
                    IN VALUES ( 'Type'[Attribute] )
                        && 'Table'[Value] IN VALUES ( 'True/False'[Value] )
            )
        ),
        CALCULATE ( COUNTROWS ( 'Table' ) )
    ),
    CALCULATE ( COUNTROWS ( 'Table' ) )
)

 

Then put the following field to a chart visual

vxinruzhumsft_4-1734664725919.png

 

Then  put the columns of true/false table and type table to the visual filter of the chart visual.

vxinruzhumsft_6-1734665006154.png

 

Output

vxinruzhumsft_7-1734665033314.png

 

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

4 REPLIES 4
v-xinruzhu-msft
Community Support
Community Support

Hi,

Thanks for the solution ryan_mayu  offered, and i want to offer some more infotmation for user to refer to.

hello @hollyse , you can refer to the following sample.

Sample data 

vxinruzhumsft_0-1734664507905.png

1.Unpivot the data to the following.

vxinruzhumsft_1-1734664551087.png

2.Create the following tables, there are no relationships among the tables.

True/Fales table

vxinruzhumsft_2-1734664583919.png

 

Type table

vxinruzhumsft_3-1734664600724.png

Then create the following measure.

 

MEASURE =
IF (
    ISFILTERED ( 'Type'[Attribute] ) && ISFILTERED ( 'True/False'[Value] ),
    IF (
        SELECTEDVALUE ( 'Table'[Attribute] ) IN VALUES ( 'Type'[Attribute] ),
        CALCULATE (
            COUNTROWS ( 'Table' ),
            FILTER (
                'Table',
                'Table'[Attribute]
                    IN VALUES ( 'Type'[Attribute] )
                        && 'Table'[Value] IN VALUES ( 'True/False'[Value] )
            )
        ),
        CALCULATE ( COUNTROWS ( 'Table' ) )
    ),
    CALCULATE ( COUNTROWS ( 'Table' ) )
)

 

Then put the following field to a chart visual

vxinruzhumsft_4-1734664725919.png

 

Then  put the columns of true/false table and type table to the visual filter of the chart visual.

vxinruzhumsft_6-1734665006154.png

 

Output

vxinruzhumsft_7-1734665033314.png

 

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

ryan_mayu
Super User
Super User

could you pls provide some sample data and expected output?





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




I have 3 columns. 

1 All Active

2 Active and Opened 30+ Days

3 Active and Updated 5+ Days Ago

hollyse_0-1734618809954.png

 

When i change the filter on one, like on the 2nd one to Opened 30+ Days=True, then it seems to mess with the other columns.

hollyse_1-1734618864642.png

 

Now in the above just the ones Active and Opened 30+ Days are showing. (And Updated 5+ Days ago shows all because i didn't add the filter yet to=True)

maybe you need to use the filter in the DAX, not the visual filter. Visual filter has the higher priority, so that will affect on the whole visual. 

Please provide some sample data (excel file or pbix file or paste the data in the reply) and the expected output based on the sample data.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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