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

Be 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

Reply
Alex_pg
Advocate I
Advocate I

Select a column to show in chart based on slicer having only one selected value

Hi,

 

I have been trying to create a donut chart that would automatically drill down based on a slicer selection having only one value selected.

 

Dataset is simple, [Major category] [Minor category] [Total].

Major category | Minor category | Total
A                        | 1                       | 20

A                        | 2                       | 55

A                        | 3                       | 36

B                        | 1                       | 8
B                        | 2                       | 3

 

In the report there is a [Major category] slicer.

There also is a donut chart that displays the [Total] based on [Major category].

 

I would like to find a way to automatically change the detail of the donut to [Minor category] if/when only one [Major category] is selected in the slicer.

 

I am not sure how to do this (I am open to suggestion - Columns / measure / table).

I tried a if condition in a table but it did not work.

_TBL_DONUT_CHART =
IF(
    DISTINCTCOUNT([Major category])=1
    ,SUMMARIZECOLUMNS(
       [Minor category]
        ,"sum_Total"
        ,SUM([Total])
    )
    ,SUMMARIZECOLUMNS(
        [Major category]
        ,"sum_Total"
        ,SUM([Total])
    )
)


Hopefully this make sense.

 

Regards,

 

Alex

1 ACCEPTED SOLUTION

Why not just use the built in drill-down feature of the pie chart? So when someone clicks a slice of Major pie, it expands to all the Minor slices of that Major slice?

View solution in original post

3 REPLIES 3
parry2k
Super User
Super User

@Alex_pg There is no method to auto drill-down to the next level based on the selection in the slicer. 



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Why not just use the built in drill-down feature of the pie chart? So when someone clicks a slice of Major pie, it expands to all the Minor slices of that Major slice?

I just wanted to limit the number of clicks since there is already a filter in the report.
I will just use the drill-down I guess.

Thank you all

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!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.