ClickHouse / ClickHouse/clickhouse-java
[Client, JDBC] Support Aggregate Functions
- Dominant language
- Java
- Stars
- 1.6k
- Forks
- 636
- Avg merge
- 2d 23h
- Merged PRs (30d)
- 29
Description
### Description
There is currently only SimpleAggregate function columns are supported and partially.
Related to https://github.com/dbeaver/dbeaver/issues/29931
Example table:
```SQL
CREATE TABLE signoz_metrics.exp_hist
(
`env` LowCardinality(String) DEFAULT 'default',
`temporality` LowCardinality(String) DEFAULT 'Unspecified',
`metric_name` LowCardinality(String),
`fingerprint` UInt64 CODEC(Delta(8), ZSTD(1)),
`unix_milli` Int64 CODEC(DoubleDelta, ZSTD(1)),
`count` UInt64 CODEC(ZSTD(1)),
`sum` Float64 CODEC(Gorilla, ZSTD(1)),
`min` Float64 CODEC(Gorilla, ZSTD(1)),
`max` Float64 CODEC(Gorilla, ZSTD(1)),
`sketch` AggregateFunction(quantilesDD(0.01, 0.5, 0.75, 0.9, 0.95, 0.99), UInt64) CODEC(ZSTD(1))
)
ENGINE = MergeTree
PARTITION BY toDate(unix_milli / 1000)
ORDER BY (env, temporality, metric_name, fingerprint, unix_milli)
TTL toDateTime(unix_milli / 1000) + toIntervalSecond(2592000)
SETTINGS ttl_only_drop_parts = 1,
index_granularity = 8192;
```
Contributor guide
Research direction
Start by tracing the JDBC client handling for ClickHouse AggregateFunction columns. Reproduce the behavior with the provided signoz_metrics.exp_hist CREATE TABLE, especially its quantilesDD sketch column, and compare it with the related issue #29931. Done means AggregateFunction columns are supported consistently rather than only partially.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100