This repository has been archived on 2024-07-22. You can view files and clone it, but cannot push or open issues or pull requests.
otter-space-sdk/db/migrations/007_create_table_PostReference_2024_06_04.sql

12 lines
295 B
MySQL
Raw Normal View History

-- +migrate Up
CREATE TABLE "PostReference"
(
post_id TEXT REFERENCES "Post" (id),
source_id TEXT REFERENCES "Source" (id),
url TEXT NOT NULL UNIQUE,
source_post_id TEXT,
PRIMARY KEY (post_id, source_id)
);
-- +migrate Down
DROP TABLE "PostReference";