feat: ✨ let database handles creation times
This commit is contained in:
parent
1e8d656711
commit
dca2abb62a
10 changed files with 22 additions and 22 deletions
|
@ -1,6 +1,6 @@
|
|||
-- Add up migration script here
|
||||
CREATE TABLE IF NOT EXISTS "post"(
|
||||
creation_time TIMESTAMPTZ PRIMARY KEY UNIQUE NOT NULL,
|
||||
creation_time TIMESTAMPTZ PRIMARY KEY UNIQUE NOT NULL DEFAULT NOW(),
|
||||
poster_id BIGSERIAL NOT NULL REFERENCES "user"(id),
|
||||
post VARCHAR NOT NULL UNIQUE
|
||||
);
|
Loading…
Add table
Add a link
Reference in a new issue