Skip to content

Instantly share code, notes, and snippets.

@zabih-alipour
Created July 10, 2019 08:45
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 zabih-alipour/090943843f5a9361059a8cdd9afe420d to your computer and use it in GitHub Desktop.
Save zabih-alipour/090943843f5a9361059a8cdd9afe420d to your computer and use it in GitHub Desktop.
WITH cte AS (
SELECT current_date - (n || ' day')::INTERVAL AS date
FROM generate_series(0, 29) n
)
SELECT date
FROM cte
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment