diff options
Diffstat (limited to 'util/updates/update_1.21.sql')
-rw-r--r-- | util/updates/update_1.21.sql | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/util/updates/update_1.21.sql b/util/updates/update_1.21.sql index c8457498..176f9056 100644 --- a/util/updates/update_1.21.sql +++ b/util/updates/update_1.21.sql @@ -1,12 +1,16 @@ -- screenshots ---CREATE SEQUENCE screenshots_seq; +CREATE TABLE screenshots ( + id SERIAL NOT NULL PRIMARY KEY, + status smallint NOT NULL DEFAULT 0, -- 0:unprocessed, 1:processed, <0:error (unimplemented) + width smallint NOT NULL DEFAULT 0, + height smallint NOT NULL DEFAULT 0 +) WITHOUT OIDS; CREATE TABLE vn_screenshots ( - vid integer NOT NULL DEFAULT 0 REFERENCES vn_rev (id) DEFERRABLE INITIALLY DEFERRED, - scr integer NOT NULL DEFAULT 0, + vid integer NOT NULL DEFAULT 0 REFERENCES vn_rev (id) DEFERRABLE INITIALLY DEFERRED, + scr integer NOT NULL DEFAULT 0 REFERENCES screenshots (id) DEFERRABLE INITIALLY DEFERRED, nsfw smallint NOT NULL DEFAULT 0, PRIMARY KEY(vid, scr) ) WITHOUT OIDS; - |