Forum Discussion
Relationship Issue
- 10 months ago
hello Hussein_charif
as mentioned by rohit1991 , the problem with many-to-many is power bi can not tell which to which when you have repeating id.
sharing my experience for many-to-many relationship in my previous project, i created a calculated column in both table for "dummy" unique id which come from concatenate two column.
this way is better than having relationship only from one column which has repeating id.
Hope this will help.
Thank you.
Hussein_charif Hey,
I will follow below steps to troubleshoot.
Many-to-many relationship between "Journals" and "Structure" is complex and can lead to ambiguous filtering. Consider if a one-to-many relationship is possible, restructuring as needed.
Set up filter directions carefully. Single direction (Journal filters Structure) can resolve ambiguity in cases where IDs show 0 amounts. It ensures Journals are the context within which Structure is evaluated.
Ensure the bridge table is correctly configured. It should contain unique IDs linking Journals and Structure properly. Validate its effectiveness in managing filter propagation.
Examine the logic creating the StructureID concatenation. Consider adding columns like Project Flag separately in Structure for filtering ease.
Calculated Columns/Measures:
- Create calculated columns or measures to handle specific scenarios instead of relying solely on relationships.
- For cases with only MainAccount, devise measures to aggregate/assign amounts differently.
- Use Power BI’s “Performance Analyzer” to trace incorrect computation paths.
- Temporarily remove relationships, verify expected outputs via DAX, and adapt based on findings.
- Use report table configurations to ensure visibility with proper amounts on IDs with only MainAccount. Consider conditional logic in DAX to handle nulls or blanks delicately.
Thanks
Harish M