piccolo_admin
piccolo_admin copied to clipboard
Unique Together
Hi! Thanks for the last update! While building our app we faced one more lack of functionality in the ORM
Do you have plans to implement "unique together" feature (for two or more fields)? Even sqlite supports it, very useful thing
The same in django, https://stackoverflow.com/questions/2201598/how-to-define-two-fields-unique-as-couple
@shattl You're right, this needs adding.
There's a PR for it currently - https://github.com/piccolo-orm/piccolo/pull/582, which is quite close to be being done.
So hopefully it won't be too long.
In the mean time, you can get around it using a migration with raw SQL for adding / deleting the unique together constraints.