forked from IQSS/dataverse
-
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.
get deployment working again for new installations IQSS#6165
- Loading branch information
Showing
1 changed file
with
3 additions
and
3 deletions.
There are no files selected for viewing
6 changes: 3 additions & 3 deletions
6
src/main/resources/db/migration/V4.16.0.1__5303-addColumn-to-settingTable.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 |
---|---|---|
@@ -1,13 +1,13 @@ | ||
ALTER TABLE ONLY setting DROP CONSTRAINT setting_pkey ; | ||
|
||
ALTER TABLE setting ADD COLUMN ID SERIAL PRIMARY KEY; | ||
ALTER TABLE setting ADD COLUMN IF NOT EXISTS ID SERIAL PRIMARY KEY; | ||
|
||
ALTER TABLE setting ADD COLUMN lang text; | ||
ALTER TABLE setting ADD COLUMN IF NOT EXISTS lang text; | ||
|
||
ALTER TABLE setting | ||
ADD CONSTRAINT non_empty_lang | ||
CHECK (lang <> ''); | ||
|
||
CREATE UNIQUE INDEX unique_settings | ||
ON setting | ||
(name, coalesce(lang, '')); | ||
(name, coalesce(lang, '')); |