CREATE TABLE IF NOT EXISTS photos (
	name TEXT UNIQUE,
	original TEXT UNIQUE,
	hash TEXT UNIQUE,
	width INTEGER,
	height INTEGER,
	filmstock TEXT,
	discovered INTEGER,
	created INTEGER,
	updated INTEGER,
	posted INTEGER DEFAULT 0,
	score INTEGER DEFAULT 0,
	deleted INTEGER DEFAULT 0
);

CREATE TABLE IF NOT EXISTS version (
	id TEXT PRIMARY KEY,
	updated INTEGER UNIQUE
)