diff options
Diffstat (limited to 'db/db.sql')
-rw-r--r-- | db/db.sql | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -5,9 +5,10 @@ CREATE DATABASE clog; CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; CREATE TABLE posts ( - id UUID PRIMARY KEY DEFAULT uuid_generate_v4(), - title CHARACTER VARYING NOT NULL, - body CHARACTER VARYING NOT NULL, - created_at TIMESTAMP NOT NULL DEFAULT NOW(), - updated_at TIMESTAMP NOT NULL DEFAULT NOW() + id UUID PRIMARY KEY DEFAULT uuid_generate_v4(), + -- draft BOOLEAN NOT NULL DEFAULT TRUE, + title CHARACTER VARYING NOT NULL, + body CHARACTER VARYING NOT NULL, + created_at TIMESTAMP NOT NULL DEFAULT NOW(), + updated_at TIMESTAMP NOT NULL DEFAULT NOW() ); |