-
Notifications
You must be signed in to change notification settings - Fork 0
/
schema.sql
48 lines (44 loc) · 911 Bytes
/
schema.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
DROP TABLE metadata;
CREATE TABLE metadata (
key VARCHAR(255),
value TEXT
);
DROP TABLE feed_items;
CREATE TABLE feed_items (
id SERIAL PRIMARY KEY,
title TEXT,
link TEXT,
text TEXT,
created TIMESTAMP,
published TIMESTAMP
);
DROP TABLE categories;
CREATE TABLE categories (
id SERIAL PRIMARY KEY,
next_id INT,
prev_id INT,
name VARCHAR(255),
slug VARCHAR(255),
description TEXT
);
DROP TABLE sections;
CREATE TABLE sections (
id SERIAL PRIMARY KEY,
next_id INT,
prev_id INT,
name VARCHAR(255),
slug VARCHAR(255),
description TEXT,
category INT
);
DROP TABLE data_items;
CREATE TABLE data_items (
id SERIAL PRIMARY KEY,
next_id INT,
prev_id INT,
title TEXT,
link TEXT,
text TEXT,
meta TEXT,
section INT
);