Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago

show only child values based on parent selection

Hi All,

I am trying to create a chart that shows the values of all the child under the parent when it is selected in the filter.

For example when I select Continent (example: Asia), it should only show me the Sub Continents (example: Central Asia, Eastern Asia...etc) in the chart.
And the same for when I select Sub-Continent (Example: Southern Asia) it should only show the countries in Southern Asia (Afganistan,Bangladesh, Bhutan....etc) in the chart.

Unfortunately, I cannot only rely on the expand next level function on the chart to do it and need it to automatically change based on the selection.

Please kindly let me know if there is a way I can do it with a Dax Measure or any other way. 

 

This is what it shows:

But I want to show it like this with out having to press the next level button on the chart. 

 

 

Thanks

8 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Icon for Community Champion rankCommunity Champion

    Anonymous - What does your source data look like?

    Not really enough information to go on, please first check if your issue is a common issue listed here: https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882

    Also, please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

    The most important parts are:
    1. Sample data as text, use the table tool in the editing bar
    2. Expected output from sample data
    3. Explanation in words of how to get from 1. to 2.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Greg_Deckler 

       

      I have provided more info as requested. Please kindly let me know if you need anything else to help me with the issue. 

      Thanks in advance for you help. 

      Thanks

  • Anonymous's avatar
    Anonymous
    Not applicable

    HI All,

     

    Thank you for the response.

    Please find some of the details requested for my question. 

    I have attached a link to the PBIX file. 

    Link: https://drive.google.com/file/d/1HTt33Y5s-FhzWDXt9-GJeZw0_R-gMqS8/view?usp=sharing

     

    The data is from UN migration database

     

    Here is a snippit of my data:

    what I am trying to do is create a watefall chart that shows the different levels under the hierarchy.

     

    For example, when I select ASIA from the filter this is what the chart shows:

    but I want it to show like this, without selecting the expand next level button:

    then if i choose Central Asia or any other Sub Continent- it shows me the below:

    But instead i want it to show me all the cities with in Central Asia without using the expand next level button. 

    Please kindly let me know if you need any more information, but the PBIX file has the data in it. technically it is very simple to do with the expand next level button on the chart but I cannot use that button for the pursposes of my dashboard. 

     

    Please let me knoe if there is any other solution to it. 

     

    Thanks

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

    Maybe you could select the hierarchy in Axis directly as below

    And for Slicer ,edit interactions so that it will not filter other visuals.

    https://docs.microsoft.com/en-us/power-bi/create-reports/service-reports-visual-interactions

     

    You could take a look at my pbix file here

     

    Did I answer your question ? Please mark my reply as solution. Thank you very much.

    If not, please upload some insensitive data samples and expected output.

     

    Best Regards,

    Eyelyn Qin