Skip to content

Commit

Permalink
Minor spacing fix in migration files.
Browse files Browse the repository at this point in the history
  • Loading branch information
bakar-io committed Apr 10, 2024
1 parent 6f38105 commit 6712f38
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions backend/migrations/000003_create_user.down.sql
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ALTER TABLE assistant
DROP CONSTRAINT fk_assistant_user_id,
ALTER COLUMN user_id TYPE VARCHAR USING (user_id::text);
DROP CONSTRAINT fk_assistant_user_id,
ALTER COLUMN user_id TYPE VARCHAR USING (user_id::text);

ALTER TABLE thread
DROP CONSTRAINT fk_thread_user_id,
Expand Down
8 changes: 4 additions & 4 deletions backend/migrations/000003_create_user.up.sql
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ WHERE user_id IS NOT NULL
ON CONFLICT (user_id) DO NOTHING;

ALTER TABLE assistant
ALTER COLUMN user_id TYPE UUID USING (user_id::UUID),
ADD CONSTRAINT fk_assistant_user_id FOREIGN KEY (user_id) REFERENCES "user"(user_id);
ALTER COLUMN user_id TYPE UUID USING (user_id::UUID),
ADD CONSTRAINT fk_assistant_user_id FOREIGN KEY (user_id) REFERENCES "user"(user_id);

ALTER TABLE thread
ALTER COLUMN user_id TYPE UUID USING (user_id::UUID),
ADD CONSTRAINT fk_thread_user_id FOREIGN KEY (user_id) REFERENCES "user"(user_id);
ALTER COLUMN user_id TYPE UUID USING (user_id::UUID),
ADD CONSTRAINT fk_thread_user_id FOREIGN KEY (user_id) REFERENCES "user"(user_id);

0 comments on commit 6712f38

Please sign in to comment.