61
Multi-Column Unique Constraint in Directus App
Source: directus/directus#13673 · opened by @ravi-2912
It would be nice to have a multiple column unique constraint for SQL tables that can be managed from within the Directus platform. At the minute, if using PostgreSQL, this has to be done by directly writing SQL query and executing it in the database. The query is
Having a UI for this would be a very usefull and this can be done in the Model page within the Settings Module similar to Duplication Field.
A UI can be built where the user can check multiple columns to be set as unique together. For an existing unique together constraint if the user unchecks a column then the constraint needs to be altered. Likewise, if user unchecks all checked columns then remove the unique together constraint. Unique together constraint does not need to exist with columns of related tables.
Having a UI for this would be a very usefull and this can be done in the Model page within the Settings Module similar to Duplication Field.
A UI can be built where the user can check multiple columns to be set as unique together. For an existing unique together constraint if the user unchecks a column then the constraint needs to be altered. Likewise, if user unchecks all checked columns then remove the unique together constraint. Unique together constraint does not need to exist with columns of related tables.
No pledges yet. Be the first to back this.
Comments
Similar requests
Support custom CSS classes for backend form interface and add unique identifier for interfaces
3 votes · 0 comments
Get all related collections/items for m2o,m2m without reverse fields
2 votes · 0 comments
Why Isn't Directus Gaining More Attention in Mobile App Development?
10 votes · 0 comments
Directus Loader for Astro Content Layer
41 votes · 0 comments
Ability to login to directus using access token of a configured provider.
2 votes · 0 comments
No comments yet.