Does StarRocks have 1. *toStartOfMonth* <https://c...
# questions-and-troubleshooting
c
Does StarRocks have 1. toStartOfMonth https://clickhouse.com/docs/sql-reference/functions/date-time-functions#toStartOfMonth or 2. toStartOfInterval https://clickhouse.com/docs/sql-reference/functions/date-time-functions#toStartOfInterval Basically, given a datetime, return the beginning of the month,
Copy code
select toStartOfMonth(now());

   ┌─toStartOfMonth(now())─┐
1. │            2025-10-01 │
   └───────────────────────┘
r
use
date_trunc('month', now());
🚀 1
1
👍 1