Skip to content

Instantly share code, notes, and snippets.

@pgp44
Created April 14, 2019 05:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pgp44/d12ef36c6ab0015bf5993ddbbe1bd10e to your computer and use it in GitHub Desktop.
Save pgp44/d12ef36c6ab0015bf5993ddbbe1bd10e to your computer and use it in GitHub Desktop.
with recursive inputparams as (
select 260 as BucketSize
),
...
timeseries as (
select * from (
select '2019–04–01 23:59:00'::timestamp, 3504
union select '2019–04–01 23:58:00'::timestamp, 3488
...
) tab(timestamp,value)
),
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment