photosite/sql/setup.sql

22 lines
422 B
SQL

CREATE TABLE IF NOT EXISTS photos (
id TEXT PRIMARY KEY,
name TEXT UNIQUE,
original TEXT UNIQUE,
hash TEXT UNIQUE,
width INTEGER,
height INTEGER,
format TEXT,
filmstock TEXT,
location TEXT,
discovered INTEGER,
created INTEGER,
updated INTEGER,
bsky INTEGER DEFAULT 0,
score INTEGER DEFAULT 0,
deleted INTEGER DEFAULT 0
);
CREATE TABLE IF NOT EXISTS version (
id TEXT PRIMARY KEY,
updated INTEGER UNIQUE
)