Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

One to One relationship in Data Model

Hi Experts

 

 Are one to one relationships a good Idea in a data model? I have tried to Summarise the Entity ID column in both Tables (Payment and Requested Received) and when i connect the two tables using a bridge table i still get a one to one relationship. 

 

Connecting Payment and Requested Received directly based on Entity ID gives me one to one.....

 

 

  • Anonymous 

    It is prefereable to avoid bi-directional relationships (as is a one-to-one). Besides, you might find that a table may "grow" in rows changing that side of the relationship from being a "One" to becoming a "Many". If the relationship is set as one-to-one you will get an error when loading the model.

     

    You can actually change the relationship under the properties. Here is one example (ignore the model; it's for illustrations purposes only):

     

     

    If you later need to filter the dimension table there are several ways of doing so.

2 Replies

  • PaulDBrown's avatar
    PaulDBrown
    Community Champion

    Anonymous 

    It is prefereable to avoid bi-directional relationships (as is a one-to-one). Besides, you might find that a table may "grow" in rows changing that side of the relationship from being a "One" to becoming a "Many". If the relationship is set as one-to-one you will get an error when loading the model.

     

    You can actually change the relationship under the properties. Here is one example (ignore the model; it's for illustrations purposes only):

     

     

    If you later need to filter the dimension table there are several ways of doing so.