Add person table.
Import mail associated with -user specified on commandline.
This commit is contained in:
27
pq/init.sql
27
pq/init.sql
@@ -1,7 +1,24 @@
|
||||
DROP TABLE files;
|
||||
DROP TABLE original;
|
||||
DROP TABLE person;
|
||||
|
||||
CREATE TABLE files (
|
||||
hash CHAR(40),
|
||||
path TEXT
|
||||
);
|
||||
|
||||
CREATE TABLE person (
|
||||
uid SERIAL UNIQUE,
|
||||
username TEXT,
|
||||
name TEXT
|
||||
);
|
||||
|
||||
INSERT INTO person (username, name) VALUES ('wathiede', 'Bill Thiede');
|
||||
|
||||
CREATE TABLE original (
|
||||
hash char(40) PRIMARY KEY,
|
||||
header_size integer,
|
||||
total_size integer,
|
||||
blob bytea
|
||||
)
|
||||
uid INTEGER REFERENCES person (uid),
|
||||
hash CHAR(40) PRIMARY KEY,
|
||||
header_size INTEGER,
|
||||
total_size INTEGER,
|
||||
blob BYTEA
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user