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 | ||||
|         ,greatest(least(o.sdate,gld.edat),gld.sdat) sdate | ||||
|         ,ss.ssyr sseas | ||||
|         ,o."version" | ||||
|         ,o.iter | ||||
|         ,'actuals' "version" | ||||
|         ,'actuals' iter | ||||
|     FROM | ||||
|         rlarp.osm_dev o | ||||
|         --snap the ship dates of the historic fiscal period | ||||
| @ -544,8 +544,8 @@ gld AS ( | ||||
|         ,o.rseas | ||||
|         ,greatest(least(o.sdate,gld.edat),gld.sdat) | ||||
|         ,ss.ssyr | ||||
|         ,o."version" | ||||
|         ,o.iter | ||||
|         --,o."version" | ||||
|         --,o.iter | ||||
| ) | ||||
| --create a union of overlapped actuals and forecast with  | ||||
| --forecast as negative and actuals as positive such that | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user