Question: Why do Nullability Rules Updated at the Column Level not Reflect in the Relationship Editor?
For a Non-Identifying Relationship, erwin Data Modeler allows has Null options at both the column and relationship level.
Column Level:
Relationship Level:
At the relationship level, updating from 'Nulls Allowed' to 'Nulls Not Allowed', also changes the corresponding Null option for the Column from 'Null' to 'Not Null'. However, in the Column editor, switching from 'Not Null' back to 'Null'. does not change the nullability in Relationship editor. Why does this occur?
Answer: This is by design, to provide more flexibility in modeling. In most cases, the nullability option in Relationship editor should be same as in the Column Editor. However, consider a scenario in which there are more than one column as part of the PK. In this case, it it is possible not all columns will share the same nullability behavior. For example:
Default behavior (see the Nullability)
After changing the nullability in Relationship editor (see nullability changes to 'Not Null' for ALL FKs.
However, if you want to change the nullability of specific columns, you can do so in Column editor to show it as follows:
Please also be aware that erwin Data Modeler 2020r1 also introduces a new option to enhance productivity. Under Tools --> Options, a new option "Enforce Relationship Nullability Rules" exists.
This option specifies whether you want to apply nullability rules configured at the Relationship level for columns. If enabled...
- The Null Option of the relationship reflects the Null Option of the migrated attribute.
- In case of compound relationship:
- - If the Null Option of one of the migrated attributes is set to NULL, the Null Option of the relationship is set to NULLS ALLOWED.
- - If the Null Option of all the migrated attributes is set to NOT NULL, the Null Option of the relationship is set to NULLS NOT ALLOWED.
More information here:
Comments
0 comments
Please sign in to leave a comment.