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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Filtering related data

Hey wonderful PBI community

 

I'm trying to look at unique moments and filter related moments on the same id to show how often those related moments occore when selecting an indivual moment. 

 

for example when I click on "Dead Air" I want to see the trend of the "negitive" and "positive sentinment", unfortunatley when you click off the current "Dead Air" selection it clears the top line chart. Ideally I want the top chart to show overall "negitive and positive sentinment", then when you click on "Dead Air" it shows the related occorance of "positive" and "negitive". Maybe there's an easy solution to this I'm not thinking of. 

example1.JPG

Here is an example file of the data I'm working with 

"how to get related id's" page is the one in question

pbix file 

 

Thanks in advance, the community has been fantastic for working out pbi problems!

1 ACCEPTED SOLUTION
v-kkf-msft
Community Support
Community Support

Hi @Anonymous ,

 

Try the following formula:

 

Measure = 
IF(
    ISFILTERED('Comparison Moment'[Comparison Moment]),
    [match %],
    DIVIDE(
        DISTINCTCOUNT(Main_Data_Set[id]),
        CALCULATE( DISTINCTCOUNT(Main_Data_Set[id]), ALL(Main_Data_Set) )
    )
)

 image.png

 

If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.

Best Regards,
Winniz

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

7 REPLIES 7
v-kkf-msft
Community Support
Community Support

Hi @Anonymous ,

 

Try the following formula:

 

Measure = 
IF(
    ISFILTERED('Comparison Moment'[Comparison Moment]),
    [match %],
    DIVIDE(
        DISTINCTCOUNT(Main_Data_Set[id]),
        CALCULATE( DISTINCTCOUNT(Main_Data_Set[id]), ALL(Main_Data_Set) )
    )
)

 image.png

 

If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.

Best Regards,
Winniz

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

Anonymous
Not applicable

so this doesn't seem to quite work as expected. 

 

the top graph should be in the 80% range when un-filtered. 

Hi @Anonymous ,

 

Try the following formula:

 

Measure = 
IF(
    ISFILTERED('Comparison Moment'[Comparison Moment]),
    [match %],
    DIVIDE(
        DISTINCTCOUNT(Main_Data_Set[id]),
        CALCULATE( DISTINCTCOUNT(Main_Data_Set[id]), ALLSELECTED('Main Moment'[Main Moment]), ALL(Main_Data_Set[date]) )
    )
)

 image.png

 

If the problem is still not resolved, please provide detailed error information or the expected result you expect. Let me know immediately, looking forward to your reply.

 

Best Regards,
Winniz

Anonymous
Not applicable

So what I'm going for is when I slect Product x4 for example is to see only the tickets with those id's and if those tickets have Positive or Negitive sentinement so the count of either could be a max of 3 in this example Capturex.JPG

Hi @Anonymous ,

 

I'm not sure what kind of output you want. I created some simple data to help me understand. Could you tell me what kind of result you want to show in the line chart based on the following data?

 

image.png

 

Best Regards,
Winniz

lbendlin
Super User
Super User

Is your default interaction cross filtering or cross highlighting?

Anonymous
Not applicable

filtering, looking to click on one moment, then see those moments and how frequently they show up on the associated id's 

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

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.