diff flys-backend/doc/schema/oracle-minfo.sql @ 2816:70b4a31a3306

Implemented the method stubs of the parser for sediment density and made some db schema adaptions. flys-backend/trunk@4233 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Fri, 13 Apr 2012 10:59:15 +0000
parents a36a5407acbf
children 8979f2294af9
line wrap: on
line diff
--- a/flys-backend/doc/schema/oracle-minfo.sql	Fri Apr 13 09:57:37 2012 +0000
+++ b/flys-backend/doc/schema/oracle-minfo.sql	Fri Apr 13 10:59:15 2012 +0000
@@ -122,9 +122,11 @@
     id          NUMBER(38,0) NOT NULL,
     river_id    NUMBER(38,0) NOT NULL,
     depth_id    NUMBER(38,0) NOT NULL,
+    unit_id     NUMBER(38,0) NOT NULL,
     PRIMARY KEY(id),
     CONSTRAINT fk_sd_river_id FOREIGN KEY (river_id) REFERENCES rivers(id),
-    CONSTRAINT fk_sd_depth_id FOREIGN KEY (depth_id) REFERENCES depths(id)
+    CONSTRAINT fk_sd_depth_id FOREIGN KEY (depth_id) REFERENCES depths(id),
+    CONSTRAINT fk_sd_unit_id FOREIGN KEY (unit_id) REFERENCES units(id)
 );
 
 
@@ -133,10 +135,9 @@
 CREATE TABLE sediment_density_values (
     id                  NUMBER(38,0) NOT NULL,
     sediment_density_id NUMBER(38,0) NOT NULL,
-    station_id          NUMBER(38,0) NOT NULL,
+    station             NUMBER(38,2) NOT NULL,
     density             NUMBER(38,2) NOT NULL,
     description         VARCHAR(256),
     PRIMARY KEY(id),
-    CONSTRAINT fk_sdv_sediment_density_id FOREIGN KEY(sediment_density_id) REFERENCES sediment_density(id),
-    CONSTRAINT fk_sdv_station_id FOREIGN KEY (station_id) REFERENCES ranges(id)
+    CONSTRAINT fk_sdv_sediment_density_id FOREIGN KEY(sediment_density_id) REFERENCES sediment_density(id)
 );

http://dive4elements.wald.intevation.org