On Wed, 19 Apr 2017, Mike Dewhirst wrote:
> You probably need a single FK plus a meta option of unique_together
> https://docs.djangoproject.com/en/1.8/ref/models/options/#unique-together
Mike,
Okay. What would be the correct syntax for
PRIMARY KEY unique_together=('company', 'person', 'proj_nbr')
> Use the model's clean() method ...
> https://docs.djangoproject.com/en/1.8/ref/models/instances/#django.db.models.Model.clean
This I'll need to ponder more to figure out where to put the clean method
so it validates entries before they're saved.
Thanks,
Rich
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment