calathea/migrations/2025-01-16-195902_images/up.sql

11 lines
298 B
SQL

create table images (
id integer primary key not null,
plant_id integer not null
references plants (id)
-- Keep entries in the database so the files can be removed later
on delete set null,
date_taken date not null,
mime_type text not null,
note text
);