Last active
October 7, 2021 09:43
-
-
Save morsapaes/834e40f582e799896ae17c4f5adfffb5 to your computer and use it in GitHub Desktop.
Analyzing Twitch streams with Materialize: what are the most popular games?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE MATERIALIZED VIEW mv_agg_stream_game AS | |
SELECT game_id, | |
game_name, | |
COUNT(id) AS cnt_streams, | |
SUM(viewer_count) AS agg_viewer_cnt | |
FROM v_twitch_stream | |
WHERE game_id IS NOT NULL | |
GROUP BY game_id, game_name; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment