Skip to main content
Skip to main content

Alternative Query Languages

Besides standard SQL, ClickHouse supports various alternative query languages for querying data.

The currently supported dialects are:

Which query language is used is controlled by setting dialect.

Standard SQL

Standard SQL is the default query language of ClickHouse.

SET dialect = 'clickhouse'

Pipelined relational query language (PRQL)

Experimental feature. Learn more.

To enable PRQL:

SET allow_experimental_prql_dialect = 1; -- this SET statement is required only for ClickHouse versions >= v25.1
SET dialect = 'prql'

Example PRQL query:

from trips
aggregate {
    ct = count this
    total_days = sum days
}

Under the hood, ClickHouse uses transpilation from PRQL to SQL to run PRQL queries.

Kusto query language (KQL)

Experimental feature. Learn more.

To enable KQL:

SET allow_experimental_kusto_dialect = 1; -- this SET statement is required only for ClickHouse versions >= 25.1
SET dialect = 'kusto'
numbers(10) | project number
┌─number─┐
│      0 │
│      1 │
│      2 │
│      3 │
│      4 │
│      5 │
│      6 │
│      7 │
│      8 │
│      9 │
└────────┘

Note that KQL queries may not be able to access all functions defined in ClickHouse.