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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
nok0620
Frequent Visitor

Visual Interactions - pie chart not working properly

There're two piecharts on my dashboard. When I click on one of the areas of piechart A (by country), piechart B (only YES or NO) should highlight and flag out values regarding that particular area of piechart A. However, piechart B fails to reflect to real numbers.

 

i.e.

 

Piechart A

HK     30  (2 YES, 28 NO)

SG      20  (11 YES, 9 NO)

JP       50  (30 YES, 20 NO)

AU     15  (all YES)

 

Piechart B

YES    58

NO     57

 

Piechart still shows NO with (57) when I click on AU, it should be zero.
Any idea why this happens ? Thanks.

 

1 ACCEPTED SOLUTION

This is really weird. Let's do some tests.

 

1. Use this measure instead of the automatic count:

CountMeaseure=
var Number=DISTINCTCOUNT(Name)
return
IF(
    Number=BLANK();
    0;
    Number
)

 

2. Tell me if the mouseover value is right.

 

3. Try with the differents Label styles.

View solution in original post

15 REPLIES 15
GeorgeBuster
Advocate III
Advocate III

Hi Nok0620,

 

The first cause might be that the piecharts are not connected by the "Edit Interactions" tool of Power BI Desktop.

1. Select the piechart A.

2. Click in the top Menu: Format>Edit Iteractions.

3. Test the icons on the piechart B are ON (you can select filter o highlight).

 

The second option might be that your tables, which join the data of country and YES/NO, have an incorrect relationship. Test that the fields that join those tables are right and also that the direction of the relationship allows filter as you want.

 

Best,

Jorge Bustillo.

I'm a beginner and was very confused why my piechart A was filtering but not my piechart B. You saved my day. Thanks a lot!

I've tried to re-do the "Edit Interactions", piechart A and B are actually from the same table.

From the screen-cap you can see the YES/NO chart after highlighting area in piechart A.

The numbers in YES did change, NO should be 0 but it remains as the old number.

Capture.JPG

Thanks for the help though Smiley Tongue

 

Well, see what I've developed and find what differences you could have. Otherwise, tell us more about your table and we try to help you.

 

Captura.PNGCaptura1.PNGCaptura2.PNGCaptura3.PNG

 

Best,

Jorge Bustillo.

sorry, I may have simplified the dummy data in a wrong way lol

The data is like

- NAME

- COUNTRY

- YES/NO

- AGE GROUP (IF YES, age group is provided. If NO, age group is blank)

When I click on "blank" in piechart AgeGroup,

Capture4.JPG

 

The data just highlighted the NO but not turning YES to zero.

 

When I click on the other age group, it turns like this

 

Capture3.JPGCapture2.JPG

 

I see, highlighting works fine, so your problem is the measure that represent the data value. Please tell us what measure is and how is set in the piecharts? You can do a test setting the interaction between piecharts as a filter instead of highlighting.

THe YES/NO is not a measure (cal field) but a static value. The four columns are pulled from Oracle DB directly.

With Piechart AGEGROUP:      Details: AGE GROUP       Value: Count of Name

With Piechart YES/NO:            Details: YES/NO              Value: Count of Name

 

Interactions work fine when set as filter, just the highlighting interaction gives the non-zero presentation.

 

Ok Nok0620, everything (filter and highlight) works fine but the numbers displayed. The problem is in the table, if you could show some screenshot of sample data or similar would be very useful, thank you.

There you go.

 

Capture5.jpg

 

Sample highlighting that doesn't show correct value (Third chart, the NO(587) should be NO(0))

 

Capture6.JPG

The table is like mine, and the measure (count of) is also like mine. There it musn't be the problem. Why do you have some data labels with ( ) and others just the number? What kind of detail label have you set?

Just discovered in your table, the number doesn't drop to zero as well. Is there any way to make Power BI update the value to 0?

Label setting is as follows btw,

Capture7.JPG

In my piecharts the numbers work fine, the problem with the automatic measure (count of) is that when is zero for Power BI is blank and he doesn't show a number. This behaviour is easy to solve authoring our measure with an IF blank return 0.

 

Please, show me the format tab as in this image:

Captura.PNG

O, right. when u highlight UK, the N displays correctly without any value beside.

But for mine, not sure why the (587) remains beside NO. Smiley Frustrated

 

Capture8.JPG

This is really weird. Let's do some tests.

 

1. Use this measure instead of the automatic count:

CountMeaseure=
var Number=DISTINCTCOUNT(Name)
return
IF(
    Number=BLANK();
    0;
    Number
)

 

2. Tell me if the mouseover value is right.

 

3. Try with the differents Label styles.

Capture9.JPG

The value turns to zero normally, probably I'll make a new measure in the future instead of dragging "Count of XX" directly in Values firectly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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