I have an entity consisting of some fix attributes and some variable attributes which should be versioned. This leads to a database design having a table for the fix parts (Table F
) and a table for the versioned parts (Table V
).
V
has a many to one relation to F
(one entity many have many versions). F
has a one to one relation to one V
to indicate the current version. This leads to circular dependencies in our database making life hard.
We prefer a solution ensuring data consitency on database level (so setting a currentversoin-flag on V
is no solution, since we can't ensure there are not multiple current versions in case of failure). Do you see any better way to modell this without circles?