turbot/hackernews_insights

Query: hackernews_dashboard_stories_by_hour

Usage

powerpipe query hackernews_insights.query.hackernews_dashboard_stories_by_hour

SQL

with data as (
(select * from hackernews_new where $1 = 'New')
union
(select * from hackernews_top where $1 = 'Top')
union
(select * from hackernews_best where $1 = 'Best')
)
select
to_char(time::timestamptz,'MM-DD HH24:00') as hour,
count(*)
from
data
group by
hour
order by
hour;

Params

ArgsNameDefaultDescriptionVariable
$1story_type

    Dashboards

    The query is used in the dashboards: