add blueprint code column script
This commit is contained in:
parent
841c9a3060
commit
cdb19efaa6
|
@ -0,0 +1,13 @@
|
||||||
|
DO $$DECLARE
|
||||||
|
this_version CONSTANT varchar := '00.01.071';
|
||||||
|
BEGIN
|
||||||
|
PERFORM * FROM "DBVersion" WHERE version = this_version;
|
||||||
|
IF FOUND THEN RETURN; END IF;
|
||||||
|
|
||||||
|
ALTER TABLE public."PlanBlueprint" ADD COLUMN code character varying(200);
|
||||||
|
UPDATE public."PlanBlueprint" SET code = group_id;
|
||||||
|
ALTER TABLE public."PlanBlueprint" ALTER COLUMN code SET NOT NULL;
|
||||||
|
|
||||||
|
INSERT INTO public."DBVersion" VALUES ('DMPDB', '00.01.071', '2024-07-29 12:00:00.000000+02', now(), 'Add PlanBlueprint code column.');
|
||||||
|
|
||||||
|
END$$;
|
Loading…
Reference in New Issue