summaryrefslogtreecommitdiff
path: root/src/schema.sql
blob: 92fba4bbf279a9d0733ea414719f3e74730425ac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
CREATE TABLE posts (
  post_id MEDIUMINT UNSIGNED,
  message_id VARCHAR(255) NOT NULL,
  in_reply_to VARCHAR(255),
  edit_id MEDIUMINT NOT NULL AUTO_INCREMENT,
  UNIQUE KEY (message_id),
  PRIMARY KEY (edit_id),
  INDEX (post_id)
);

CREATE TABLE forums (
  list_name VARCHAR(255) NOT NULL,
  forum_id MEDIUMINT UNSIGNED NOT NULL,
  PRIMARY KEY (list_name),
  INDEX (forum_id)
);