Skip to content

Commit

Permalink
Start user and site_member tables.
Browse files Browse the repository at this point in the history
  • Loading branch information
emmiegit committed Jan 14, 2024
1 parent af5227a commit 1b92901
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions migrations/20240112_01_Njk7j-create-initial-tables.sql
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,29 @@ CREATE TABLE site (
UNIQUE (wikidot_id)
);

CREATE TABLE "user" (
user_slug TEXT PRIMARY KEY,
user_name TEXT,
wikidot_id INTEGER,
created_at TIMESTAMP,
account_type TEXT,
real_name TEXT,
bio TEXT,
karma SMALLINT,
website TEXT,
gender TEXT,

UNIQUE (wikidot_id)
);

CREATE TABLE site_member (
user_id INTEGER,
site_id INTEGER,
joined_at TIMESTAMP WITH TIME ZONE NOT NULL,

PRIMARY KEY (user_id, site_id)
);

-- Content-based hash using kangarootwelve
CREATE TABLE text (
hash BYTEA PRIMARY KEY,
Expand Down

0 comments on commit 1b92901

Please sign in to comment.