Truncate
date_trunc('month', ts) rounds a timestamp down to the start of its month. On a timestamptz it uses the session time zone, so pin the zone.
task
Orders per calendar month (UTC). Return the month start and the count.
Run a query to see rows here.
Run EXPLAIN on the statement under the cursor: Plan tab, button Explain.
No tables yet.
date_trunc('month', ts) rounds a timestamp down to the start of its month. On a timestamptz it uses the session time zone, so pin the zone.
Orders per calendar month (UTC). Return the month start and the count.