From d8ae1be2ffae9285722a6016cc301ddd8a818c04 Mon Sep 17 00:00:00 2001 From: El RIDO Date: Sun, 1 Nov 2015 17:10:36 +0100 Subject: [PATCH] updating database documentation --- INSTALL.md | 25 ++++++++++++++++++------- 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/INSTALL.md b/INSTALL.md index 3da4c6f..afcd2c4 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -76,20 +76,31 @@ any experience running ZeroBin on other RDBMS, please let us know. For reference or if you want to create the table schema for yourself: CREATE TABLE prefix_paste ( - dataid CHAR(16), - data TEXT, + dataid CHAR(16) NOT NULL, + data BLOB, postdate INT, expiredate INT, opendiscussion INT, - burnafterreading INT + burnafterreading INT, + meta TEXT, + attachment MEDIUMBLOB, + attachmentname BLOB, + PRIMARY KEY (dataid) ); CREATE TABLE prefix_comment ( dataid CHAR(16), pasteid CHAR(16), parentid CHAR(16), - data TEXT, - nickname VARCHAR(255), - vizhash TEXT, - postdate INT + data BLOB, + nickname BLOB, + vizhash BLOB, + postdate INT, + PRIMARY KEY (dataid) ); + CREATE INDEX parent ON prefix_comment(pasteid); + + CREATE TABLE prefix_config ( + id CHAR(16) NOT NULL, value TEXT, PRIMARY KEY (id) + ); + INSERT INTO prefix_config VALUES('VERSION', '0.22');