increment cutoff date for actuals

This commit is contained in:
Paul Trowbridge 2020-05-05 11:31:27 -04:00
parent 9826b5f810
commit 474b133915
2 changed files with 4 additions and 4 deletions

View File

@ -1,6 +1,6 @@
DELETE FROM rlarp.osmf_dev WHERE odate < '2020-04-01';
INSERT INTO rlarp.osmf_dev SELECT * FROM rlarp.osmfs_dev WHERE odate < '2020-04-01';
DELETE FROM rlarp.osmf_dev WHERE odate < '2020-05-01';
INSERT INTO rlarp.osmf_dev SELECT * FROM rlarp.osmfs_dev WHERE odate < '2020-05-01';

View File

@ -145,9 +145,9 @@ gld AS (
WHERE
(
--base period orders booked....
o.odate <@ daterange('2019-06-01','2020-04-01')
o.odate <@ daterange('2019-06-01','2020-05-01')
--...or any open orders currently booked before cutoff....
OR (o.calc_status IN ('OPEN','BACKORDER') and o.odate < '2020-04-01')
OR (o.calc_status IN ('OPEN','BACKORDER') and o.odate < '2020-05-01')
--...or anything that shipped in that period
OR o.fspr BETWEEN '2001' AND '2010'
)