Mercurial > lada > lada-server
diff db_schema/lada_schema.sql @ 1045:61b94641cf99
A period with end before start is not meaningful.
This is true for the subintervall, too.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Thu, 08 Sep 2016 12:03:43 +0200 |
parents | a796e68da1cf |
children | 3c9616e5439f |
line wrap: on
line diff
--- a/db_schema/lada_schema.sql Wed Sep 07 18:17:48 2016 +0200 +++ b/db_schema/lada_schema.sql Thu Sep 08 12:03:43 2016 +0200 @@ -588,6 +588,7 @@ probe_nehmer_id integer, probe_kommentar character varying(80), letzte_aenderung timestamp without time zone DEFAULT now() NOT NULL, + CHECK (teilintervall_von <= teilintervall_bis), CHECK (gueltig_von <= gueltig_bis) ); CREATE TRIGGER letzte_aenderung_messprogramm BEFORE UPDATE ON messprogramm FOR EACH ROW EXECUTE PROCEDURE update_letzte_aenderung();