[Dive4elements-commits] [PATCH] Schema change: remove UNIQUE-constraint from rivers.official number as we have different representations of the same river (e.g. for sommer and winter)

Wald Commits scm-commit at wald.intevation.org
Fri May 3 07:47:20 CEST 2013


# HG changeset patch
# User Tom Gottfried <tom at intevation.de>
# Date 1367560035 -7200
# Node ID c1abd48a03e24aeb4b47718a57b375e8178dd262
# Parent  9a3ca7532f2a190a5fa68df4d0d234d90a223d9b
Schema change: remove UNIQUE-constraint from rivers.official number as we have different representations of the same river (e.g. for sommer and winter)

diff -r 9a3ca7532f2a -r c1abd48a03e2 backend/doc/schema/oracle.sql
--- a/backend/doc/schema/oracle.sql	Thu May 02 21:23:44 2013 +0200
+++ b/backend/doc/schema/oracle.sql	Fri May 03 07:47:15 2013 +0200
@@ -260,7 +260,7 @@
 
 CREATE TABLE rivers (
     id                  NUMBER(38,0) NOT NULL,
-    official_number     NUMBER(38,0) UNIQUE,
+    official_number     NUMBER(38,0),
     km_up               NUMBER(38,0) NOT NULL DEFAULT 0,
     name                VARCHAR2(255) NOT NULL UNIQUE,
     wst_unit_id         NUMBER(38,0) NOT NULL,
diff -r 9a3ca7532f2a -r c1abd48a03e2 backend/doc/schema/postgresql.sql
--- a/backend/doc/schema/postgresql.sql	Thu May 02 21:23:44 2013 +0200
+++ b/backend/doc/schema/postgresql.sql	Fri May 03 07:47:15 2013 +0200
@@ -12,7 +12,7 @@
 
 CREATE TABLE rivers (
     id              int PRIMARY KEY NOT NULL,
-    official_number int8                     UNIQUE,
+    official_number int8,
     name            VARCHAR(256)    NOT NULL UNIQUE,
     km_up           BOOLEAN         NOT NULL DEFAULT true,
     wst_unit_id int                 NOT NULL REFERENCES units(id)


More information about the Dive4elements-commits mailing list