1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-25 04:24:20 +00:00
royalnet/migrations/2024-08-05-175443_add_diario/up.sql
Stefano Pigozzi 437f3cf565
Add /diario command (#11)
Co-authored-by: Lorenzo Rossi <snowycoder@gmail.com>
2024-08-08 00:36:39 +02:00

13 lines
367 B
SQL

CREATE TABLE diario (
id INT PRIMARY KEY GENERATED BY DEFAULT AS IDENTITY(START 10000),
saver_id INT REFERENCES users (id) DEFAULT null,
saved_on TIMESTAMP DEFAULT now(),
quoted_id INT REFERENCES users (id) DEFAULT null,
quoted_name VARCHAR DEFAULT null,
warning TEXT DEFAULT null,
quote TEXT NOT NULL,
context TEXT DEFAULT null
);