Created
April 23, 2015 15:38
-
-
Save arbarlow/e48601f301e5912ec739 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- +goose Up | |
CREATE TABLE photos ( | |
id uuid primary key default uuid_generate_v4() NOT NULL, | |
reel_id uuid NOT NULL REFERENCES reels(id), | |
path text NOT NULL, | |
thumbnail text, | |
bytes bigint NOT NULL, | |
rev text NOT NULL, | |
exif text, | |
cleaned boolean NOT NULL default false, | |
updated_at timestamp NOT NULL default now(), | |
created_at timestamp NOT NULL default now(), | |
deleted_at timestamp | |
); | |
CREATE UNIQUE INDEX photos_reel_rev ON photos(reel_id, rev); | |
-- +goose Down | |
DROP TABLE photos; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment