Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Total Sum based on a column from other table

Hi,    I have a table with two columns from a dimension table (Company and Project) with a Revenue column coming from the Project Fact Table. Both table are related by Project ID.   I wanted to u...
  • v-luwang-msft's avatar
    5 years ago

    Hi Anonymous ,

    A relationship can be set to be unidirectional – its default behavior – or bidirectional. In a unidirectional relationship the filter context is propagated from the one-side to the many-side, but not the other way around. In other words, in your diagram a filter on Fact Project Revenue automatically filters Dim_LF_project, whereas a filter on Dim_LF_project propagates neither to Fact Project Revenue.

    And the presence of that bidirectional cross-filter introduces ambiguity in the model. A model is ambiguous when there are multiple paths between tables. In an ambiguous model, the engine has multiple options when transferring a filter from one table to another. Therefore, it either finds a preferred way to transfer the filter, or it raises an error. In this scenario, no error was raised; therefore, either the model is not ambiguous (small spoiler: IT IS AMBIGUOUS), or the engine found a preferred way to transfer the filter.

    To learn more details ,refer:

    https://www.sqlbi.com/articles/bidirectional-relationships-and-ambiguity-in-dax/ 

    https://docs.microsoft.com/en-us/power-bi/guidance/relationships-bidirectional-filtering 

     

    Wish it is helpful for you!

     

    Best Regards

    Lucien