11 lines
271 B
MySQL
11 lines
271 B
MySQL
|
CREATE TABLE posts (
|
||
|
id SERIAL PRIMARY KEY,
|
||
|
title VARCHAR NOT NULL,
|
||
|
content TEXT NOT NULL,
|
||
|
published BOOLEAN NOT NULL DEFAULT 'f',
|
||
|
views integer NOT NULL DEFAULT 0,
|
||
|
created_at TIMESTAMP NOT NULL DEFAULT NOW(),
|
||
|
updated_at TIMESTAMP NOT NULL DEFAULT NOW()
|
||
|
)
|
||
|
|