pantry-track/sites/test/sql/create/locations.sql
2024-10-20 10:03:14 -05:00

11 lines
286 B
SQL

CREATE TABLE IF NOT EXISTS test_locations(
id SERIAL PRIMARY KEY,
uuid VARCHAR(255) NOT NULL,
name VARCHAR(32) NOT NULL,
zone_id INTEGER NOT NULL,
items JSONB,
UNIQUE(uuid),
CONSTRAINT fk_zone
FOREIGN KEY(zone_id)
REFERENCES test_zones(id)
);