-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added tables to mark messages as false negative (#27)
- Loading branch information
Showing
1 changed file
with
21 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
CREATE TABLE false_positive_users | ||
( | ||
user_id BIGINT PRIMARY KEY | ||
REFERENCES "user" (id) ON DELETE CASCADE | ||
); | ||
|
||
CREATE TABLE false_positive_messages | ||
( | ||
chat_id BIGINT NOT NULL, | ||
message_id INT NOT NULL, | ||
PRIMARY KEY (chat_id, message_id), | ||
FOREIGN KEY (chat_id, message_id) REFERENCES "message" (chat_id, message_id) ON DELETE CASCADE | ||
); | ||
|
||
CREATE TABLE false_negative_messages | ||
( | ||
chat_id BIGINT NOT NULL, | ||
message_id INT NOT NULL, | ||
PRIMARY KEY (chat_id, message_id), | ||
FOREIGN KEY (chat_id, message_id) REFERENCES "message" (chat_id, message_id) ON DELETE CASCADE | ||
); |