comparison flys-backend/doc/schema/postgresql.sql @ 493:b35c5dc0f8b7

Importer: Make import of historical discharge tables work. flys-backend/trunk@1842 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Fri, 06 May 2011 10:27:32 +0000
parents 77f337650211
children 4f2d8980415f
comparison
equal deleted inserted replaced
492:14de9246b356 493:b35c5dc0f8b7
112 CREATE SEQUENCE DISCHARGE_TABLES_ID_SEQ; 112 CREATE SEQUENCE DISCHARGE_TABLES_ID_SEQ;
113 113
114 CREATE TABLE discharge_tables ( 114 CREATE TABLE discharge_tables (
115 id int PRIMARY KEY NOT NULL, 115 id int PRIMARY KEY NOT NULL,
116 gauge_id int NOT NULL REFERENCES gauges(id), 116 gauge_id int NOT NULL REFERENCES gauges(id),
117 description VARCHAR(256) NOT NULL,
117 kind int NOT NULL DEFAULT 0, 118 kind int NOT NULL DEFAULT 0,
118 time_interval_id int REFERENCES time_intervals(id), 119 time_interval_id int REFERENCES time_intervals(id),
119 120
120 -- TODO: better checks 121 -- TODO: better checks
121 UNIQUE (gauge_id, time_interval_id) 122 UNIQUE (gauge_id, time_interval_id)

http://dive4elements.wald.intevation.org