Introduction
One of the key goals of recent ClickHouse® releases has been improving compatibility with the ANSI SQL standard. While ClickHouse has always offered a rich set of date and time functions, some syntax differences compared to traditional relational databases required developers to modify existing SQL queries during migrations.
A common example was retrieving the current date or timestamp. Earlier versions of ClickHouse relied on function calls such as today() and now(), whereas many popular databases use SQL-standard keywords like CURRENT_DATE and CURRENT_TIMESTAMP.
ClickHouse® 26.3 bridges this gap by introducing support for SQL-standard time functions without parentheses. Although this may seem like a small enhancement, it significantly improves portability for applications, BI tools, reporting platforms, and ORMs that generate ANSI SQL.
In this article, we'll explore what's new, how these functions work, and why this seemingly simple feature makes migrating workloads to ClickHouse much easier.
Why SQL Compatibility Matters
Organizations rarely build analytics platforms from scratch.
Many migrate workloads from databases such as:
- PostgreSQL
- MySQL
- SQL Server
- Oracle
- Snowflake
These systems generally follow ANSI SQL syntax for obtaining the current date and timestamp.
For example:
SELECT CURRENT_DATE;
SELECT CURRENT_TIMESTAMP;
Prior to ClickHouse® 26.3, these queries required modification before they could run successfully.
Even small syntax differences become significant when migrating:
- Thousands of SQL queries
- BI dashboards
- Stored reports
- ORM-generated SQL
- Data transformation pipelines
Reducing these incompatibilities simplifies migrations and improves developer productivity.
Before ClickHouse® 26.3
Traditionally, ClickHouse used dedicated functions.
SELECT today();
SELECT now();
These functions remain fully supported and continue to be the recommended native ClickHouse approach.
However, applications written for ANSI SQL databases often expected keyword-based syntax instead.
What's New in ClickHouse® 26.3?
ClickHouse® 26.3 introduces support for several SQL-standard temporal keywords without requiring parentheses.
Supported syntax includes:
SELECT CURRENT_DATE;
SELECT CURRENT_TIMESTAMP;
SELECT NOW;
These expressions behave exactly like their ClickHouse counterparts while following the SQL standard used by many other database systems.
Function Comparison
| SQL Standard | Traditional ClickHouse® | Supported in 26.3 |
|---|---|---|
CURRENT_DATE |
today() |
✅ Yes |
CURRENT_TIMESTAMP |
now() |
✅ Yes |
NOW |
now() |
✅ Yes (without parentheses) |
These additions provide alternative syntax—they do not replace existing ClickHouse functions.
Examples
Current Date
SELECT CURRENT_DATE;
Equivalent native ClickHouse syntax:
SELECT today();
Example output:
2026-03-18
Current Timestamp
SELECT CURRENT_TIMESTAMP;
Equivalent ClickHouse function:
SELECT now();
Example output:
2026-03-18 14:35:12
NOW Without Parentheses
Before ClickHouse® 26.3:
SELECT now();
Now you can simply write:
SELECT NOW;
Both statements return the same current timestamp.
Why This Matters for Migrations
Many migration projects involve moving hundreds or thousands of SQL statements from existing analytical databases into ClickHouse.
Consider a PostgreSQL query:
SELECT
CURRENT_DATE,
CURRENT_TIMESTAMP;
Earlier versions required rewriting this as:
SELECT
today(),
now();
With ClickHouse® 26.3, the original SQL can often run unchanged.
This reduces migration effort while improving compatibility with third-party SQL generators.
Better Support for BI Tools
Many reporting platforms automatically generate ANSI SQL.
Examples include:
- Apache Superset
- Metabase
- Tableau
- Power BI
- Looker
- JDBC-based reporting tools
Because these tools frequently generate CURRENT_DATE or CURRENT_TIMESTAMP, ClickHouse now accepts these expressions without requiring query modifications.
This helps reduce compatibility issues during deployment.
Existing Date and Time Functions Remain Available
It's important to note that ClickHouse® 26.3 does not introduce a new date-time engine.
All existing functions remain available, including:
today()now()toDate()