comparison flys-backend/doc/schema/postgresql.sql @ 173:8e2f2ddc507f

Fixed wrong spelled column references in foreign keys introduces with last change. flys-backend/trunk@1465 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Mon, 14 Mar 2011 15:40:14 +0000
parents 4a83e14f40f9
children 249390dd24e7
comparison
equal deleted inserted replaced
172:605320b7df94 173:8e2f2ddc507f
147 -- columns of WST files 147 -- columns of WST files
148 CREATE SEQUENCE WST_COLUMNS_ID_SEQ; 148 CREATE SEQUENCE WST_COLUMNS_ID_SEQ;
149 149
150 CREATE TABLE wst_columns ( 150 CREATE TABLE wst_columns (
151 id int PRIMARY KEY NOT NULL, 151 id int PRIMARY KEY NOT NULL,
152 wst_id int NOT NULL REFERENCES wst(id), 152 wst_id int NOT NULL REFERENCES wsts(id),
153 name VARCHAR(256) NOT NULL, 153 name VARCHAR(256) NOT NULL,
154 description VARCHAR, 154 description VARCHAR,
155 155
156 time_interval_id int REFERENCES time_intervals(id), 156 time_interval_id int REFERENCES time_intervals(id),
157 157
183 -- bind q ranges to wst columns 183 -- bind q ranges to wst columns
184 CREATE SEQUENCE WST_COLUMN_Q_RANGES_ID_SEQ; 184 CREATE SEQUENCE WST_COLUMN_Q_RANGES_ID_SEQ;
185 185
186 CREATE TABLE wst_column_q_ranges ( 186 CREATE TABLE wst_column_q_ranges (
187 id int PRIMARY KEY NOT NULL, 187 id int PRIMARY KEY NOT NULL,
188 wst_column_id int NOT NULL REFERENCES wst_column(id), 188 wst_column_id int NOT NULL REFERENCES wst_columns(id),
189 wst_q_range_id int NOT NULL REFERENCES wst_q_ranges(id), 189 wst_q_range_id int NOT NULL REFERENCES wst_q_ranges(id),
190 190
191 UNIQUE (wst_column_id, wst_q_range_id) 191 UNIQUE (wst_column_id, wst_q_range_id)
192 ); 192 );
193 193

http://dive4elements.wald.intevation.org