-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #26 from cabinetoffice/fix/unique-constraints
Adding unique constraints to apply DB
- Loading branch information
Showing
2 changed files
with
6 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
src/main/resources/db/migration/V1_64__add_unique_constraints_to_users.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
ALTER TABLE gap_user ADD CONSTRAINT unique_user_sub UNIQUE (user_sub); | ||
ALTER TABLE grant_applicant ADD CONSTRAINT unique_user_id UNIQUE (user_id); | ||
ALTER TABLE grant_admin ADD CONSTRAINT unique_user_id UNIQUE (user_id); | ||
ALTER TABLE grant_applicant_organisation_profile ADD CONSTRAINT unique_applicant_id UNIQUE (applicant_id); |