Skip to content

Instantly share code, notes, and snippets.

@kleong
Created July 30, 2019 20:26
Show Gist options
  • Save kleong/4866a6b79ea063093d2cd6de9f170c18 to your computer and use it in GitHub Desktop.
Save kleong/4866a6b79ea063093d2cd6de9f170c18 to your computer and use it in GitHub Desktop.
SELECT t.timestamp_ms,
t.created_at AS created_at,
t.text AS text,
t.user.screen_name AS screen_name
FROM "twitter-kinesis-demo" t
WHERE CAST(timestamp_ms AS INT) > UNIX_MILLIS(current_timestamp() - minutes(1))
ORDER BY timestamp_ms DESC
LIMIT 100;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment