messages schema now ready to be used

This commit is contained in:
shockrah 2020-07-05 20:48:15 -07:00
parent f827cef9c5
commit 1944152252
2 changed files with 10 additions and 0 deletions

View File

@ -0,0 +1 @@
DROP TABLE `messages`;

View File

@ -0,0 +1,9 @@
CREATE TABLE IF NOT EXISTS `messages`(
`id` BIGINT UNSIGNED NOT NULL,
`content` VARCHAR(2048),
`author_id` BIGINT UNSIGNED NOT NULL,
`channel_id` BIGINT UNSIGNED NOT NULL,
PRIMARY KEY (`id`),
FOREIGN KEY (`author_id`) REFERENCES members(`id`),
FOREIGN KEY (`channel_id`) REFERENCES channels(`id`)
);