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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
N_A_S_H
Regular Visitor

Measure Not working on Sankey Chart

Hi,

I am doing basic CDR Analysis. I want to use the Sankey Chart to show the flow of communication between common connections only. Common connection is defined as single dimBParty[B-Party] connected to multiple dimAParty[A-Party]. 

My data model has two dimension tables dimAParty and dimBParty connected to CDR fact table. I created a measure to filter the common connections only i.e. count distinct A-Parties per B-Party.

 

 

DistinctAPartyCount = 
CALCULATE(
    DISTINCTCOUNT(dimAParty[A-Party]),
    CDR
)

 

 

 

The measure seems to work fine when I use it as a filter in a matrix visual - DistinctAPartyCount > 1.

However, when I use it to filter the common connections in a Sankey Chart, the chart goes blank.
Link to the "Sample CDR.pbix" file. 
Please help with the correct measure.  Thank you. 

 
1 ACCEPTED SOLUTION

Hi @N_A_S_H ,

 

Thanks for your reply. I reviewed a while and found that the cause.

You can observe that it's the gaps caused by issues with the order of your visual fields. The positions of A party and B party are reversed.

vstephenmsft_0-1732525261909.pngvstephenmsft_1-1732525289547.png

Similarly, your matrix has a row B-Party at the top and a column at the bottom with A-Party. Your filter is to show the value when the count of A-Party is greater than 1.

vstephenmsft_2-1732525441470.png

It would be more intuitive if you replaced Grand Total with a filter's metric, as follows:

For each row of the B-Party, the distinctcounting of A-Party with 03004444444 is 1 and will be filtered out. Others greater than 1 will be retained.

vstephenmsft_3-1732525637650.png

At this point I put A-Party in the row and B-Party in the column, as follows:

vstephenmsft_4-1732525812930.png

You can see that, A-Party is assigned to each row, so the distinctcounting of A-Party in each row is 1, which is the filter condition when the distinctcounting of A-Party is greater than 1, all rows will be filtered out.

vstephenmsft_6-1732525965595.png

Summary: This question involves the row context, if you are interested, you can refer to:

Row context in DAX - SQLBI

Context in DAX Formulas - Microsoft Support

 

Best Regards,

Stephen Tao

 

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-stephen-msft
Community Support
Community Support

Hi @N_A_S_H ,

 

You should note that your measure is placed as a filter at the visual level.

vstephenmsft_1-1731566671040.png

Then I tested it, and the measure filter was placed in the matrix, and it was also empty.

vstephenmsft_0-1731566637244.png

Please provide more details of your issue.

 

Best Regards,

Stephen Tao

 

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

 

Hi @v-stephen-msft,

Please take a look at the second page of the report for the measure output.

 

Screenshot 2024-11-21 131304.png

 

Hi @N_A_S_H ,

 

Thanks for your reply. I reviewed a while and found that the cause.

You can observe that it's the gaps caused by issues with the order of your visual fields. The positions of A party and B party are reversed.

vstephenmsft_0-1732525261909.pngvstephenmsft_1-1732525289547.png

Similarly, your matrix has a row B-Party at the top and a column at the bottom with A-Party. Your filter is to show the value when the count of A-Party is greater than 1.

vstephenmsft_2-1732525441470.png

It would be more intuitive if you replaced Grand Total with a filter's metric, as follows:

For each row of the B-Party, the distinctcounting of A-Party with 03004444444 is 1 and will be filtered out. Others greater than 1 will be retained.

vstephenmsft_3-1732525637650.png

At this point I put A-Party in the row and B-Party in the column, as follows:

vstephenmsft_4-1732525812930.png

You can see that, A-Party is assigned to each row, so the distinctcounting of A-Party in each row is 1, which is the filter condition when the distinctcounting of A-Party is greater than 1, all rows will be filtered out.

vstephenmsft_6-1732525965595.png

Summary: This question involves the row context, if you are interested, you can refer to:

Row context in DAX - SQLBI

Context in DAX Formulas - Microsoft Support

 

Best Regards,

Stephen Tao

 

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

 

some_bih
Super User
Super User

Hi @N_A_S_H 

I dupklicated your Sankey tab and put measure and I do get some figures, not blanks.

See results below

 

some_bih_0-1731421874218.png

 





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

Proud to be a Super User!






Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

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! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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