Extending Django Constraints to ForeignKeys with DB triggers
Extending Django check constraint to ForeignKeys with db triggers
Have you ever wanted to implement Django's check constraints and constrain a model field with checks on a particular field of a ForeignKey of the model? Django does not support it out of the box - because check constraints translate to database constraints, and no database supports it at the table constraint level. 1 2
Read More