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

Try your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now

Reply
Anonymous
Not applicable

How to change the relationship based on selection?

Hi, 

 

I have a simple problem with data connectivity in Power BI Desktop,
First, i have a donut chart showing the numbers of projects by their status for October 2020 Period, as normally, when i clicked the status, the card visualization linked to the number of projects showing the right amount of projects (101 + 1) (attached)

elvinluvian_0-1604995841260.png

elvinluvian_1-1604995883877.png

My problem is, when i changed the month to September, the card is not tally with numbers of projects mentioned in the donut chart. It still follows the number of projects from October which is 101 +1 instead of 105 in total(attached).

elvinluvian_3-1604996079858.png

additional information, here is the formula i used in donut chart values

Pie Chart Value =

SWITCH (
Selectedvalue('Table'[Month Selection]),
"September",calculate(count('Append'[Status September 2020]),userelationship(Tabel_Status[Status],'Append'[Status September 2020])),
"Oktober",calculate(count('Append'[Status Oktober 2020]),userelationship(Tabel_Status[Status],'Append'[Status Oktober 2020])),
"November",calculate(count('Append'[Status September 2020]),userelationship(Tabel_Status[Status],'Append'[Status November 2020])),
"Desember",calculate(count('Append'[Status September 2020]),userelationship(Tabel_Status[Status],'Append'[Status Desember 2020])))
 

While the legend use 

 
 

Status for Pie Chart LegendStatus for Pie Chart Legend

 and a relationship:Screenshot (668).png

 

I do know that the October relationship is in active, so the card follow the October relationship, is there any advise to linked the card to tally the number of projects in the donut chart? since the values in donut chart already reflected the 'userelationship' functions. Please advise

 

Thank You

Elvin Luvian

1 REPLY 1
v-kelly-msft
Community Support
Community Support

Hi @Anonymous ,

 

If possibel,could you pls upload your .pbix file to onedrive business and share the link with us?

 

Remember to remove the confidential information.

 

Best Regards,
Kelly

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

 

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.