Mercurial > lada > lada-server
diff db_schema/lada_schema.sql @ 1082:6499f2410c42
Fix validation of subintervall for yearly samples.
Validity and subintervall are actually redundant for yearly samples.
Giving a subintervall wider than validity will never result in
generation of samples because the start will never match validity.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Mon, 10 Oct 2016 17:23:39 +0200 |
parents | 7143cd96d3de |
children | 186d602e031a |
line wrap: on
line diff
--- a/db_schema/lada_schema.sql Mon Oct 10 16:25:12 2016 +0200 +++ b/db_schema/lada_schema.sql Mon Oct 10 17:23:39 2016 +0200 @@ -589,8 +589,8 @@ probe_kommentar character varying(80), letzte_aenderung timestamp without time zone DEFAULT now() NOT NULL, CHECK (probenintervall = 'J' - AND teilintervall_von BETWEEN 1 AND 365 - AND teilintervall_bis BETWEEN 1 AND 365 + AND teilintervall_von BETWEEN gueltig_von AND gueltig_bis + AND teilintervall_bis BETWEEN gueltig_von AND gueltig_bis AND intervall_offset BETWEEN 0 AND 364 OR probenintervall = 'H' AND teilintervall_von BETWEEN 1 AND 184