From 47ef81b31881c7fb830768f60a2c3ec8f08e0bfb Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Tue, 25 Sep 2018 13:59:09 -0400 Subject: [PATCH] function errors --- schema/functions/rollforward.sql | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/schema/functions/rollforward.sql b/schema/functions/rollforward.sql index 509216f..be064d1 100644 --- a/schema/functions/rollforward.sql +++ b/schema/functions/rollforward.sql @@ -1,6 +1,5 @@ CREATE FUNCTION evt.balrf() RETURNS void LANGUAGE plpgsql AS -DO $func$ DECLARE _mind timestamptz; @@ -22,10 +21,9 @@ BEGIN FROM evt.fspr; - IF - _maxd <= _mind + IF _maxd <= _mind THEN RETURN; - END IF + END IF; WITH --list each period in min and max