Power BI Slicer on one table not fitering joined table - powerbi

My relationship between two tables looks like this:
I use a single select slicer that filters the table [ExhibitorClass_Details]. But it is not filtering the joined table [EventMax_Details]:
Why does my slicer not filter the joined table, what am I missing?
How can I make the slicer filter both tables?

The Solution was to go under Manage Relationships and set up the "cross filter direktion":
Result:

Related

Is it possible to create a dynamic table based on another DAX table using DAX?

I need to create a kind of dynamic DAX view based on another DAX table.
First Table
Year, Category, Sub-category, Sales, Sub-Category Weight
I need to do a intermediary step different calculation for Sales on another table that looks at the above table however I can't work out how to do do it. I have a slicer populated with a subcategory dimension on the tab so every time I make a change I need the below table to reflect the chosen sub category but without it being in the table.
Second Table
Year, Category, Sub-category, Sales, Category Weight filtered by Sub-Category
I have tried the following functions:
Summarize
SummarizeColumns
CalculateTable
(think there are more)
I have tried to use each with a filter based on the slicer but I can't get it to work.

Change grouping column based on slicer selection - Power BI

I have a data set and a mapping table as below.
In Power BI, I created a slicer dropdown containing words "Finance Lens" and "Business Lens", This is created using table "Lens" and column "Lens Type"
Based on the selection, I want the grouping to change in the below visuals.
I created a new column as below :
Selected_Lens = If(SELECTEDVALUE(Lens[LensType],"Business Lens")="Business Lens",MappingTable[Business Lens],MappingTable[Finance Lens])
But it is not working... Any idea would help.

Power BI - If a date is between 2 dates using relationships

I am trying to determine if a date is between 2 other dates that are is 2 different tables using
Power BI.
For simplicity, here is the model that I have :
TableB is the bridge table between TableA and TableC.
I have an inactive relationship between tableA and TableC.
I have tried the following logic to check if TableC.createdDate is between TableA.startDate and TableA.endDate :
Create a calculated column in TableC, but I was not able to access columns in TableA
Create a calculated column in TableB, but I was having blank results, which is not suppose to happen
Have you tried using USERELATIONSHIP to force your calculated column to use the inactive relationship to TableA? documentation link
So something like
CALCULATE(
{{created date is >start and <end}},
USERELATIONSHIP('TableA'[TableB_ID],'TableC'[TableB_ID]
)

Power Bi Extract a Column value based on some another field in different Table

I have a Power BI table with some columns as given below:
Table1 - Columns(Project, Program, Name, Attribute, ID)
Example of table1:
Now I have a different measure which is used to view Power BI report. It also has some fields as given below:
Measure1 - Columns(Project, Name, Attribute, and few more)
Example of Measure:
Now I want to add ID (which is available in Table1) as Measure1 is being used to view report. How can I display ID based upon Name and Project.
Can anyone guide or help how to solve it?
If you can do this in your source Database using left join between this 2 tables.
If not, then you can use virtual relationship in DAX:
Display_ID = CALCULATE(min(Table1[ID]), TREATAS(VALUES(Table1[Project]), Measure1[Project]), TREATAS(VALUES(Table1[Name]), Measure1[Name]))

Power BI - Filter table using slicer to match within concatenated column

I've looked all over and can't find a way to do this.
In the table, I have all postcodes throughout the UK and a calculated column that concatenates from another table the products' that have been purchased in that location.
I need to filter the table to hide rows where the value selected in the slicer is in the concatenated column. I think this needs to be a measure and have tried using CONTAINSSTRING but nothing seems to be working.
Latest measure that I have tried is:
=IF(CONTAINSSTRING([Concatenated Values],[Selected Slicer Value]),"Hide","Show")
Does anyone have any ideas?
Example tables and expected results:
You can link the "another table" (the one with the products (not concatenated) per area) to the Area table.
Just change the filter option to: cross-filter direction: both
Then you can use it in your slicer.
Follow these below steps to achieve your requirement.
Let-
Your Slicer Table name: Table1
Your Details table name: Table2
Step-1: Create this following measure in Table2
show_hide_this_row =
FIND(
SELECTEDVALUE(Table1[products]),
MIN(Table2[products]),
,
0
)
Step-2: Add visual level filter using measure "show_hide_this_row" as below-
The output will be as below-
This functionality only works perfect when single selection is enabled in your slicer.