group the actuals so the timestamp on the update is excluded
This commit is contained in:
parent
1c8593a9a8
commit
a5dc4aaa85
@ -495,8 +495,8 @@ gld AS (
|
|||||||
-----when null, greatest/least is just going to act like coalesce
|
-----when null, greatest/least is just going to act like coalesce
|
||||||
,greatest(least(o.sdate,gld.edat),gld.sdat) sdate
|
,greatest(least(o.sdate,gld.edat),gld.sdat) sdate
|
||||||
,ss.ssyr sseas
|
,ss.ssyr sseas
|
||||||
,o."version"
|
,'actuals' "version"
|
||||||
,o.iter
|
,'actuals' iter
|
||||||
FROM
|
FROM
|
||||||
rlarp.osm_dev o
|
rlarp.osm_dev o
|
||||||
--snap the ship dates of the historic fiscal period
|
--snap the ship dates of the historic fiscal period
|
||||||
@ -544,8 +544,8 @@ gld AS (
|
|||||||
,o.rseas
|
,o.rseas
|
||||||
,greatest(least(o.sdate,gld.edat),gld.sdat)
|
,greatest(least(o.sdate,gld.edat),gld.sdat)
|
||||||
,ss.ssyr
|
,ss.ssyr
|
||||||
,o."version"
|
--,o."version"
|
||||||
,o.iter
|
--,o.iter
|
||||||
)
|
)
|
||||||
--create a union of overlapped actuals and forecast with
|
--create a union of overlapped actuals and forecast with
|
||||||
--forecast as negative and actuals as positive such that
|
--forecast as negative and actuals as positive such that
|
||||||
|
Loading…
Reference in New Issue
Block a user