In our Logical model, I set the 'Constraint Name' on all of the relationships automatically using a macro, for example "FK_OrderItem_to_Order".
These constraint names obviously carry through to the generated Physical model, and into the DDL.
But for subtype clusters I cannot find how to set the constraint names on the Logical model, either manually in the UI, or via the macros.
Instead, they get set automatically by ER Studio (eg. "fk_fk__2_1"), but sometimes it generates duplicates with the name "fk_fk_"
So, does anyone know how to set the constraint names, both manually in the UI, and via automation objects?
btw I can set them on the Physical model (because the subtype clusters are replaced by simple foreign keys) but I do not want to do this because we always generate a new Physical model directly from the Logical model.
I've discovered that the 'Model.Relationships' property includes subtype relationships, and therefore allows me to set the constraint/FK names for them in the logical model. But if I use 'Entity.ChildRelationships' (or Entity.ParentRelationships) the subtype relationships are NOT included! A little strange. Anyway, this has solved my issue above.
Powered by IDERA