post, comment interaction db

This commit is contained in:
Ahmet Kaan GÜMÜŞ 2024-12-05 02:21:20 +03:00
parent 60d18771d7
commit 1e8d656711
10 changed files with 184 additions and 0 deletions

View file

@ -0,0 +1,7 @@
-- Add up migration script here
CREATE TABLE IF NOT EXISTS "comment_interaction"(
comment_creation_time TIMESTAMPTZ NOT NULL REFERENCES "comment"(creation_time),
interaction_id BIGSERIAL NOT NULL REFERENCES "interaction"(id),
interactor_id BIGSERIAL NOT NULL REFERENCES "user"(id),
interaction_time TIMESTAMPTZ PRIMARY KEY NOT NULL UNIQUE
);