implement support for pinning

This commit is contained in:
insects 2025-02-11 01:45:06 +01:00
parent 9882ab74a5
commit 67709ac241
5 changed files with 117 additions and 5 deletions

View file

@ -0,0 +1,9 @@
-- Add migration script here
CREATE TABLE pinned_fish (
id SERIAL PRIMARY KEY,
account_id VARCHAR(10) NOT NULL,
fish_id INTEGER NOT NULL,
FOREIGN KEY (account_id) REFERENCES accounts (account_id) ON DELETE CASCADE ON UPDATE NO ACTION
);
CREATE INDEX pinned_fish_accounts ON pinned_fish (account_id);