The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi,
I have Entries Table with various rows, among them is "ID Number" and "Origin Country" column. There's another Target Table that registers each "Target Country" a specific ID is related to.
The idea is that entry might come from USA (Origin Country column) but it will be assigned to different countries (Target Country column) through different entries in Target Table.
Now a person responsible for specific country, knows exactly what their entries are, but would like to easily see which entries comes from other countries. I want them to select their Target Country through drop down filter, and then be able to toggle a button that will filter out all the entries, where Origin Country matches Target Country. The only entries left would be the ones that comes from Origin Country values that are not paired to selected Target Country value. I want this to respond to the Target Country selected in the drop down.
For that I created Countries Table that has "Target Country" column and "Origin Country". So a row designates that Target Country with value USA is linked to Origin Country with value USA (for example).
Any tips on how I might achieve that? I'm not sure i've described it clear enough.
Thanks!
Solved! Go to Solution.
Hi @Piotr12
For your question, here is the method I provided:
Here's some dummy data
"Entries Table"
"Target Table"
First, create relationships between tables. Relationships can be created by going to the Model view and dragging related fields between tables.
Create a measure. Check for a match between the "Origin Country" in the filter and the "Target country" selected in the filter.
OriginMatchesTarget =
IF(
CONTAINS(
'Target Table',
'Target Table'[Target Country], SELECTEDVALUE('Entries Table'[Origin Country]),
'Target Table'[Target Country], SELECTEDVALUE('Target Table'[Target Country])
),
"Match",
"No Match"
)
You may not be able to filter for matches with the button, but you can filter with the filter.
Here is the result.
Regards,
Nono Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Piotr12
For your question, here is the method I provided:
Here's some dummy data
"Entries Table"
"Target Table"
First, create relationships between tables. Relationships can be created by going to the Model view and dragging related fields between tables.
Create a measure. Check for a match between the "Origin Country" in the filter and the "Target country" selected in the filter.
OriginMatchesTarget =
IF(
CONTAINS(
'Target Table',
'Target Table'[Target Country], SELECTEDVALUE('Entries Table'[Origin Country]),
'Target Table'[Target Country], SELECTEDVALUE('Target Table'[Target Country])
),
"Match",
"No Match"
)
You may not be able to filter for matches with the button, but you can filter with the filter.
Here is the result.
Regards,
Nono Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.