Skip to content

Instantly share code, notes, and snippets.

@derekjn
Created July 9, 2015 02:54
Show Gist options
  • Save derekjn/c5b2cfc3d8dda2f4c8ad to your computer and use it in GitHub Desktop.
Save derekjn/c5b2cfc3d8dda2f4c8ad to your computer and use it in GitHub Desktop.
CREATE CONTINUOUS VIEW errors_1m AS
SELECT COUNT(*) FROM error_stream
WHERE (arrival_timestamp > clock_timestamp() - interval '1 minute');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment