i’d like to implement a simple translation based on this model. I know that there are several ways to do it but I’d like to keep it simple.
my question is about constraint… obviously i can’t create a FK relation, because I will save only the PN value in the order table, and the product PK is composite (id + language)
in order to mantain some kind of integrity (cascade delete or avoiding to delete an used product) what can I do? I’m thinking of triggers and/or business logic rules in my application code.
I’d like some opinions, thanks
Model doesn’t make sense in terms of relations, you’d have to normalise to get somewhere near
e.g
Product (ProductID(K), Description)
ProductVersions(ProductVersionID (K),ProductID (FK), Language,(FK?)) with a unique compound key on ProductID and Language.
What are they ordering anyway a product or a product/Language?