diff --git a/src/db/migrations/000014 - reference fix.sql b/src/db/migrations/000014 - reference fix.sql new file mode 100644 index 0000000..0d327ac --- /dev/null +++ b/src/db/migrations/000014 - reference fix.sql @@ -0,0 +1,3 @@ +ALTER TABLE public.reference DROP CONSTRAINT reference_uri_key; +ALTER TABLE public.reference ADD CONSTRAINT uniq__agreement_reference_uri_user_id UNIQUE (uri, user_id); +CREATE INDEX idx__public__reference__uri ON public.reference (uri);