pepperwind / answer_key /kpis /club_new_subscriptions.sql
rasinmuhammed's picture
Pepperwind Trading Co. preview, version 1.0
27ec678 verified
Raw History Blame Contribute Delete
297 Bytes
-- Club subscriptions started
-- Paid-for subscriptions by the month they started.
SELECT strftime(start_date, '%Y-%m') AS month, count(*) AS value FROM billing.subscription WHERE start_date >= TIMESTAMP '2023-10-01' AND start_date < TIMESTAMP '2026-10-01' AND (NOT is_gift) GROUP BY 1 ORDER BY 1