-
-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix migration script for epic account
- Loading branch information
1 parent
fe0fa81
commit e7a8d49
Showing
1 changed file
with
6 additions
and
6 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
CREATE TABLE IF NOT EXISTS "epic_id_mapping" ( | ||
"epic_id" varchar(64) NOT NULL, | ||
"user_id" integer NOT NULL, | ||
"last_login" integer NOT NULL, | ||
CONSTRAINT "fk_epic_id_mapping" FOREIGN KEY("user_id") REFERENCES "users"("id") ON DELETE CASCADE ON UPDATE CASCADE, | ||
CREATE UNIQUE INDEX epic_id_mapping_idx ON data(epic_id, user_id); | ||
CREATE TABLE IF NOT EXISTS epic_id_mapping ( | ||
epic_id varchar(64) NOT NULL, | ||
user_id integer NOT NULL, | ||
last_login integer NOT NULL, | ||
CONSTRAINT fk_epic_id_mapping FOREIGN KEY (user_id) REFERENCES users(id) ON DELETE CASCADE ON UPDATE CASCADE, | ||
CONSTRAINT unique_epic_user_id UNIQUE (epic_id, user_id) | ||
); |