smon/sql/00004.sql
2024-04-29 08:36:13 +02:00

3 lines
216 B
SQL

ALTER TABLE public.datapoint ADD section_id int4 NULL;
ALTER TABLE public.datapoint ADD CONSTRAINT datapoint_section_fk FOREIGN KEY (section_id) REFERENCES public."section"(id) ON DELETE SET NULL ON UPDATE SET NULL;