Forum Discussion
power bi summarize duplicate error
2 Replies
- PaulDBrownCommunity Champion
As you say, it is highly recommended to keep relationships as one-to-many. If the tables you need as slicers cannot work with one-to-many relationships, I suggest you create separate tables for each field. You can use a measure to filter the other silcers to limit selection options to actual rows of data.
Here is an example based on this simple fact table:
I've created separate tables for Company and Department using the DISTCINCT function:
The model is as follows:
Create this measure to use as a filter for each slicer, by adding it to the filters in the filter pane:
Filter Slicers = COUNTROWS(RELATEDTABLE(FTable))To get:
I've attached the sample PBIX file
- AntonioMSolution Sage
Does it work without department added? One thing you could do is remove the relationships first before you add in department and then relink the tables.