Forum Discussion
Join paths and relationship
- 8 years ago
Hi DominikTher,
Based on my test with your shared pbix file, you should be able to use the formula below to create a new measure to indicate if the Data[CountryId] is in filtered Hub, then use it to apply a visual level filter(Measure 2 is 1) on the Table visual in your scenario.
Measure 2 = IF ( CONTAINS ( HubCountry, HubCountry[CountryId], MAX ( Data[CountryId] ) ), 1, 0 )Here is the modified pbix file for your reference. :smileyhappy:
Regards
Hello v-ljerr-msft
I tried make simmilar model for demonstration. My real model is much bigger. So, there is a link to PBI file: https://file.town/download/nrwpmvf4mje3jn4kg4qoq4ilo
If you use role in this file and try to filter Hub you will see exactly same error which i posted here. In my real model i receive this error directly after i switch role (maybe beacuse i have a lot of data and connections) - but the issue is same.
If you have some tips, it would be nice :)
Thank you, Dominik
Hi DominikTher,
Based on my test with your shared pbix file, you should be able to use the formula below to create a new measure to indicate if the Data[CountryId] is in filtered Hub, then use it to apply a visual level filter(Measure 2 is 1) on the Table visual in your scenario.
Measure 2 =
IF (
CONTAINS ( HubCountry, HubCountry[CountryId], MAX ( Data[CountryId] ) ),
1,
0
)
Here is the modified pbix file for your reference. :smileyhappy:
Regards
- DominikTher8 years agoFrequent Visitor
Hello v-ljerr-msft, thanks for your solution.
Hope that someday i find solution how to get also prefiltred countries. Beacause we have lot of data and countries.
But right now your solution is very very helpful. And answer as is are acceptable :)
Thank's
And if there will be solution for Countries i post it back.
Dominik
- Anonymous7 years agoNot applicable
DominikTher I have got the same problem you had. The soluation in the thread is good to filter tables. However, the country filter is not prefiilterd. Have you found a solution? Thanks!