view backend/doc/schema/oracle_migrations/update_nachtrag_20.sql @ 9656:31549fdfaf4f

Importer (s/u-info) extensions: flow-depth: uniform formatting of from-to series names, warning instead of cancelling in case of missing column values, detecting, logging and skipping columns with wrong unit, better counting of inserted/updated values for each column
author mschaefer
date Mon, 23 Mar 2020 15:21:39 +0100
parents eb32f75c65c3
children
line wrap: on
line source
--Neues Feld infrastructure.group_id

SET AUTOCOMMIT ON;

ALTER TABLE infrastructure ADD (group_id NUMBER(38,0));

UPDATE infrastructure SET group_id=annotation_type_id;

ALTER TABLE infrastructure MODIFY (group_id NOT NULL);

ALTER TABLE infrastructure ADD CONSTRAINT cInfrastructureGroupAnnoType
      FOREIGN KEY (group_id) REFERENCES annotation_types;

COMMENT ON COLUMN infrastructure.group_id IS 'Reference to the infrastructure type group';

COMMIT;

http://dive4elements.wald.intevation.org