mirror of
https://github.com/hanzoai/datastore.git
synced 2026-09-26 13:55:07 +00:00
13,838 upstream commits, forward from the 26.6.1.1 fork point. 129 conflicts: 37 resolved mechanically (take upstream's file, re-apply the brand sweep) and 92 by hand where our fork and upstream had both changed the same code. The rule throughout: upstream owns the engine, we own the naming and a small set of deliberate deviations. Never resolve by discarding an upstream change — a dropped rename or a missed new parameter becomes a compile error a thousand files away. Deviations verified intact after the merge: ENABLE_XRAY still defaults OFF (CMakeLists.txt:105) X-Datastore-User read by the server (authenticateUserByHTTP.cpp) X-ClickHouse-* in src/ 0 hanzo/research present system.*_log retention bound present ArrowFlight rip held against upstream re-adding it Two things worth naming, because neither shows up as a conflict: src/CMakeLists.txt gained an UNGUARDED `add_object_library(datastore_storages_arrowflight Storages/ArrowFlight)` from upstream, for a directory our gRPC rip deleted. It sat outside every conflict hunk, so a resolver reading only the markers would sail straight past it into a CMake configure error. Removed; the Server/ArrowFlight sibling at line 474 stays because it is inside `if (TARGET ch_contrib::arrow_flight)`. The brand sweep had rewritten github.com/ClickHouse/ClickHouse issue links to github.com/Datastore/Datastore — a dead host. Those point at upstream's own tracker and are restored, alongside the contributors list, sql.clickhouse.com and the ClickHouse Inc copyright: attribution is theirs, not ours to rename. base/glibc-compatibility/memcpy/memcpy.h is deleted, not kept: upstream dropped it for LLVM-libc's, and our only change to it was a comment rebrand.
742 KiB
742 KiB
Watch all release presentations and videos at ClickHouse Theater and YouTube Playlist.
Table of Contents
ClickHouse release v26.6, 2026-06-25
ClickHouse release v26.5, 2026-05-21
ClickHouse release v26.4, 2026-04-30
ClickHouse release v26.3 LTS, 2026-03-26
ClickHouse release v26.2, 2026-02-26
ClickHouse release v26.1, 2026-01-29
Changelog for 2025
Changelog for 2024
Changelog for 2023
Changelog for 2022
Changelog for 2021
Changelog for 2020
Changelog for 2019
Changelog for 2018
Changelog for 2017
2026 Changelog
ClickHouse release 26.6, 2026-06-25. Presentation, Video
Backward Incompatible Change
- The change removes
allow_experimental_query_deduplicationfeature. The feature was experimental for a long time, has no tests and not going to be supported (initial tests were unstable and has been removed in #49579). #99398 (Igor Nikonov). - The XRay-based
SYSTEM INSTRUMENTfeature now usesargumentsinstead ofparameters: thesystem.instrumentation.parameterscolumn was renamed toarguments, and theSYSTEM INSTRUMENT ADD ... HANDLER PARAMETERS ...syntax was renamed toSYSTEM INSTRUMENT ADD ... HANDLER ARGUMENTS .... Queries or automation that use the old column or syntax must be updated to use the new names; the old names are no longer supported. #103854 (Pablo Marcos). - The setting
show_data_lake_catalogs_in_system_tableshas been renamed toshow_remote_databases_in_system_tablesand broadened: when its value is 0 (the default),MySQLandPostgreSQLdatabases are also hidden fromsystem.tables,system.columns, andsystem.completions, in addition to data lake catalogs. The old setting name is kept as an alias. #104416 (Pablo Marcos). - The default x86 build now targets x86-64-v3 (AVX2) instead of x86-64-v2 (SSE4.2). This requires a CPU with AVX2 support (Intel Haswell or later, AMD Excavator or later). If your CPU does not support AVX2, use the
amd64compatbuild which targets plain x86-64. #105019 (Raúl Marín). - Reject nested
Dynamic/Variantinmin/maxaggregates andminmaxindexes. Previously only top-levelDynamic/Variantwere checked. Closes #104747. #105468 (Pavel Kruglov). icebergHashandicebergBucketnow rejectInt128,UInt128,Int256,UInt256, andDecimal256arguments with an explicit error. Previously they silently truncated wider values and produced colliding hashes. The Iceberg spec only defines hashing for 32/64-bit integers and decimals with precision up to 38; cast toInt64orDecimal128to keep the previous behaviour for values that fit. #105866 (Raúl Marín).- Added granular control over query echoing in the CLI. The
--echooption now accepts an optional boolean value and works in both interactive and batch mode. New options--echo-formattedand--echo-query-idcontrol whether echoed queries are formatted and whether thequery_idis printed, respectively. The--hilite/--highlightoption now also controls highlighting of echoed queries. As a side effect,--echois now a boolean-value option, so a positional query directly after a bare--echois treated as its value; use--echo --query "..."or--echo=falseinstead. #106191 (Alexey Milovidov). - Removed the experimental KQL (Kusto) functions
array_sort_ascandarray_sort_desc, and their SQL backendskql_array_sort_ascandkql_array_sort_desc. These functions were experimental, implemented with low quality, and the source of correctness and parser bugs. Queries using these names now returnUNKNOWN_FUNCTION. #108101 (Groene AI). ALTER TABLE ... REPLACE PARTITION ... FROM ...no longer silently drops the destination partition's data when the source table has no parts in the requested partition. Previously such a request removed the destination partition and wrote nothing in its place — a data-loss footgun. It is now rejected withBAD_ARGUMENTSby default. To restore the previous silent-clear behavior, set the new settingallow_replace_partition_from_empty_source = 1, or setcompatibilityto26.5or lower; to explicitly drop destination data, useALTER TABLE ... DROP PARTITION. #104939 (Groene AI).- The default of the server setting
insert_deduplication_versionchanges fromcompatible_double_hashestonew_unified_hash. Insert deduplication now works on the whole inserted block (per insert) rather than per part/partition: a retry of the same insert is still deduplicated, but two different inserts that produce an identical part are no longer cross-deduplicated, and reordered inserts of the same rows are no longer deduplicated. Setinsert_deduplication_version = compatible_double_hashesto restore the previous behavior. Instances upgrading directly from a release that defaulted toold_separate_hashesshould first run withcompatible_double_hashesuntil the longest relevant deduplication window has elapsed before relying onnew_unified_hash. #107886 (Sema Checherinda).
New Feature
- Added support for continuous queries over
MergeTreetables, implemented via a series of snapshot reads. This is a first step toward general support for streaming queries. #105114 (Mikhail Artemenko). - Added hypothetical (what-if) skip indexes. Use
CREATE HYPOTHETICAL INDEX ... ON t (expr) TYPE ...to define a session-scoped virtual skip index, thenEXPLAIN WHATIF SELECT ...to estimate its skip ratio and cost without materializing it. Defined indexes are visible in the newsystem.hypothetical_indexestable. #104608 (Yarik Briukhovetskyi). - Add an embedded
/schemaweb UI toclickhouse-serverthat visualizes the dependency graph between tables, materialized views, refreshable materialized views, dictionaries, distributed tables and views. #105276 (Nikita Mikhaylov). - Added the
PNGoutput format support, allowing query output results to be directly rendered as PNG images. #74691 (Maksim Dergousov). - Added detection of the AI coding agent (Claude Code, Cursor, Codex, Gemini CLI, Goose, etc.) that invoked
clickhouse-clientorclickhouse-local, based on environment variables. The detected agent is reported in the newclient_agentcolumn ofsystem.query_log,system.query_thread_logandsystem.processes. #106619 (Alexey Milovidov). - Added a new system table
system.documentationthat collects the embedded reference documentation of the uniform components of the system (functions, table engines, data types, settings, formats, and others) into a single table, with the documentation rendered as Markdown. #107463 (Alexey Milovidov). - Add the
GeoJSONinput format for reading GeoJSONFeatureCollectiondocuments, producing one row per feature withid(String),geometry(Geometry), andproperties(Nullable(JSON)) columns.Point,LineString,MultiLineString,Polygon, andMultiPolygongeometries are read into ClickHouse's nativeGeometrytype.GeometryCollectionandMultiPoint, which theGeometrytype cannot represent, raise an exception by default, or can be stored asNULLvia theinput_format_geojson_unsupported_geometry_handlingsetting. Contributes to #91533. #98124 (Mark Needham). - Added functions for serving Mapbox Vector Tiles directly from SQL:
MVTEncodeGeomprojects a geometry into the pixel space of a slippy-map tile and clips it,MVTEncodeaggregates the projected geometries of a group into the binary bytes of a single-layer tile, andMVTBoundingBox/MVTBoundingBoxMercatorreturn the bounding box of a tile for restricting rows to it. Point, line and polygon geometry is supported. Also available under the PostGIS aliasesST_AsMVTGeomandST_AsMVT. #106107 (Saarthak Gupta). clickhouse-localnow supportsSYSTEM START LISTENandSYSTEM STOP LISTENqueries, allowing it to be transformed into a server accepting TCP and HTTP connections. #101143 (Alexey Milovidov).- Added an interactive
helpcommand toclickhouse-clientandclickhouse-local. Typinghelp <name>(also/help,man,/man) shows the documentation of a function, table engine, data type, format, setting, or other component, rendered from Markdown in the terminal with syntax-highlighted SQL. When the word is ambiguous all matches are shown, and when it is not found, similar names are suggested. #108042 (Alexey Milovidov). - Support writing into Azure Data Lake Storage Gen2. #105406 (Konstantin Vedernikov).
- Adding
RowBinaryWithNamesAndTypesAndDefaultsformat to get better support for schema evolution. #105736 (Mark Zitnik). - Implement
ADD ENUM VALUESinALTER TABLEqueries to simplify appending new values to an existingEnumtype without the need to specify all currentEnumvalues again. #93830 (Ilya Golshtein). - Refreshable materialized view now supports
REFRESH DEPENDS ONto trigger refreshes on another RMV's refreshes instead of time-based schedule. (REFRESH EVERY ... DEPENDS ONalready existed, but couldn't be used reliably for this use case.) SeeCREATE MATERIALIZED VIEWdocumentation. #104440 (Michael Kolupaev). - Add support for selecting columns by name pattern with
* LIKE '<pattern>'and* ILIKE '<pattern>', including qualified forms such astable.* LIKE '<pattern>'andtable.* ILIKE '<pattern>'.LIKEmatches column names case-sensitively,ILIKEcase-insensitively. #104569 (Yue Ni). - Added
ESCAPEsyntax that defines a custom escape character in aLIKEpattern, allowing you to treat%and_as literal characters instead of wildcards. #99774 (Ilya Yatsishin). - Add
materialize_projections_on_insertandmaterialize_projections_on_mergeMergeTreetable settings. Whenmaterialize_projections_on_insert = 0,INSERTs skip building projection parts, which improves insert throughput for tables with many projections. Whenmaterialize_projections_on_merge = 1, a merge rebuilds a projection that is missing from all of its source parts, so projections can be built during merges instead of on insert. Merges still combine only parts that share the same set of projections. #100993 (Christoph Wurm). - Add a new immutable
MergeTreesettingallow_tuple_element_aggregation, disabled by default. When enabled,SummingMergeTree,AggregatingMergeTreeandCoalescingMergeTreerecursively flattenTuplecolumns and aggregate each leaf element independently during merges, exactly as if it were a top-level column —SummingMergeTreesums it,AggregatingMergeTreemerges its aggregate-function state, andCoalescingMergeTreekeeps its last non-NULL value. The setting must be specified at table creation time and is silently ignored by engines that do not support it. #98039 (johnjing). - New functions
quantizeBFloat16ToInt8anddequantizeInt8ToBFloat16: a scalar codec that compresses embedding components to 8-bit using a 256-level Gaussian Lloyd-Max quantizer, from which Int4/Int2/binary codes can be extracted by bit-truncation. #108102 (Alexey Milovidov). - Add functions
arrayTopKandarrayBottomK: -arrayTopK(k, array)returns the K largest elements in descending order -arrayBottomK(k, array)returns the K smallest elements in ascending order. #104563 (Vitaly Baranov). - Added a new system table
system.iceberg_filesexposing per-file metadata forIcebergtables, with one row per data or delete file in each table's current snapshot. This closes #98777. #104415 (Asya Shneerson). - Added
system.constraintstable that provides information about allCHECKandASSUMEconstraints across all tables, including constraint name, type, and expression. #105337 (Pedro Ferreira). - Added a new
system.dictionary_layoutstable that lists the available dictionary layouts together with embedded documentation (description,syntax,examples,introduced_in,related). #106182 (Alexey Milovidov). - Added a new
system.dictionary_sourcestable that lists the available dictionary sources together with embedded documentation (description,syntax,examples,introduced_in,related). #106184 (Alexey Milovidov). - Added a new
system.data_skipping_index_typestable that lists the available data skipping index types together with embedded documentation (description,syntax,examples,introduced_in,related). #106186 (Alexey Milovidov). - Added a new
system.disk_typestable that lists the available disk types together with embedded documentation (description,syntax,examples,introduced_in,related). #106187 (Alexey Milovidov). - Implemented
SYSTEM RESTART DISK <name>: it now reloads a disk's in-memory metadata and re-scans the data parts of readonly-replica tables located on it. This lets a readonly replica of a table on sharedplain_rewritablestorage observe data written by another server on demand, without waiting forrefresh_parts_intervalor restarting the server. #106645 (Jordi Villar). - PostgreSQL-style
expr OP SOME(array)/expr OP ALL(array)(non-subquery right-hand side) is now supported and rewritten tohas/NOT hasfor=/<>, or toarrayExists/arrayAlllambdas for other comparison operators.ANYis not accepted for the array form becauseanyis also an aggregate function; useSOMEinstead. The subquery form ofANY/SOME/ALLcontinues to be lowered toIN/NOT IN. #105129 (Alexey Milovidov). - Added two new
load_balancingstrategies,hostname_longest_common_prefixandhostname_longest_common_suffix, which prefer the replica whose hostname shares the longest common prefix (respectively, suffix) with the initiator's hostname. They are useful when the data center is encoded as a prefix or suffix of hostnames whose numeric segments have variable length, where the existingnearest_hostnameandhostname_levenshtein_distancestrategies pick the wrong replica. #107360 (Denny [DBA at Innervate]). - Added TLS client certificate information (subjects, serial number, issuer, and validity period) to the
system.session_logtable to improve observability of certificate-based authentication. #107679 (Alexey Milovidov). - Add an optional
external_idcredential forS3role-based access. #106941 (Elian Gidoni). - Added a new
S3Queuesettingafter_processing_move_preserve_path. When enabled together withafter_processing='move'andafter_processing_move_prefix, processed objects are moved while preserving their full source path under the destination prefix instead of being flattened to just the file name. #105354 (Asya Shneerson). - Add
message_queue_disable_insertionserver setting to disable insertion from message queue engines (Kafka,RabbitMQ,NATS) into attached materialized views. Useful for read-only replica scenarios. #104911 (JIaQi Tang). - Added
LOCALTIMEandLOCALTIMESTAMP(SQL-standard / PostgreSQL syntax).LOCALTIMESTAMPis an alias fornow()(returnsDateTime);LOCALTIMEreturns the current time of day as aTimevalue. #106139 (Thomas Cabral). - Added
date_part('unit', expr)as syntactic sugar forEXTRACT(unit FROM expr). Standard interval kinds and the PostgreSQL extras (epoch,dow,doy,isodow,isoyear,century,decade,millennium) are all supported. #105127 (Alexey Milovidov). - PostgreSQL-compatible
EXTRACT(TIMEZONE_HOUR FROM dt)andEXTRACT(TIMEZONE_MINUTE FROM dt)for the hour and minute parts of a timezone offset, andEXTRACT(<unit> FROM INTERVAL n <unit>)/date_part('<unit>', INTERVAL n <unit>)for extracting the value out of an interval. #106227 (Vinayak Joshi). - Added
min_byandmax_byaggregate aliases forargMinandargMax. #105712 (Joey Yu). These aliases are stupid, real engineers use the original ClickHouse names. - Added
REGEXP_SUBSTRas a case-insensitive alias ofregexpExtractfor Oracle/MySQL/Snowflake compatibility. #105122 (Alexey Milovidov). - Added
SESSION_USERas a case-insensitive alias ofcurrentUser()for PostgreSQL / SQL-standard compatibility. #106081 (Takumi Hara). - Support a trailing
NULL/NOT NULLmodifier inALTER TABLE ... ADD/MODIFY COLUMN, mirroringCREATE TABLE. #106150 (Takumi Hara). - You can now use
h3PolygonToCellsWithContainmentfunction from h3 to use their new algorithm which supports center-based, fully-contained, and overlapping containment modes. #104455 (Youssef Kadry). - Adds
IPV4_PREFIX_BITS and IPV6_PREFIX_BITSflags when Keying done byIP_ADDRESSorFORWARDED_IP_ADDRESS. #89270 (Aditya Chopra). formatReadableTimeDeltanow accepts anINTERVALexpression of type other thanMonthandYearas input. #64315 (Francisco J. Jurado Moreno).- User can now specify an optional precision argument to the
formatReadableSize,formatReadableDecimalSizeandformatReadableQuantityfunctions, controlling the number of digits after the decimal point. Default is 2, preserving the prior behavior. #104648 (Antonio Filipovic). - Add
output_format_float_precisionsetting to control the number of decimal digits in floating-point text output. #99721 (phulv94). - Added a setting
output_format_always_write_decimal_point_in_float_and_decimalto always print a decimal point for floating-point andDecimalnumbers in text formats, even when the value is a whole number. For example, output1.instead of1. Disabled by default. #62614 (Ilya Yatsishin). - Add support for new HTTP handler configuration elements
<url_prefix>and<full_url_prefix>(match all paths under a base path, useful e.g. for Prometheus handlers), as well as<url_regexp>,<full_url_regexp>, and<headers_regexp>. The old<url>regex:...</url>form is now obsolete. #107492 (Vitaly Baranov). - Support
basicstatistics, a compact per-column statistic that stores numeric min/max, average string length, and NULL counts where applicable. #106048 (Han Fei). - Support TTL nodes in ClickHouse Keeper, opt-in via the
create_ttlfeature flag. #100397 (Konstantin Vedernikov). - Introduce a memory reservation feature for workloads. See the workload scheduling documentation. #82414 (Sergei Trifonov).
Experimental Feature
- Multi-stage distributed query execution: the planner splits the query plan into stages connected by scatter / broadcast / gather / shuffle exchanges and dispatches the plan fragments to worker nodes. The data between stages is streamed via TCP or passed via temporary files in shared object storage, the path supports distributed shuffle and broadcast hash joins, shuffle aggregation, and distributed sort. The feature is experimental and is disabled by default. #106020 (Alexander Gololobov). The experimental distributed query plan engine (
make_distributed_plan) can now use a different task-dispatch and streaming-exchange port per worker, configured per replica in<remote_servers>withstateless_worker_portandstreaming_exchange_port. When unset, the previous server-level ports (stateless_worker_client.portanddistributed_query.streaming_exchange_port) are used. This makes it possible to run several workers on one host. #107885 (Alexander Gololobov). - Added the experimental
dphypjoin reordering algorithm for inner joins as an option for thequery_plan_optimize_join_order_algorithmsetting, and thequery_plan_optimize_join_order_max_searched_planssetting, which bounds the join-order search and falls back to the next algorithm in the chain when the bound is exceeded; set it to0to keep the previous unbounded search behavior. #98798 (Alexander Gololobov). - Add
aiEmbedfunction for using LLM APIs to generate embeddings from within ClickHouse. #102922 (George Larionov). - Added an experimental Linux OOM canary: a sacrificial child process that the Linux OOM killer targets before the main server process. When enabled with
oom_canary_enable, it sheds memory pressure by purging allocator caches, cancelling queries, cancelling merges, and recording an event insystem.crash_log. The OOM response requires cgroup v2memory.eventsOOM-kill evidence. #101942 (Peng). - The web terminal interface at
/webterminalis now a production feature and is enabled by default. It is controlled by the newenable_webterminalserver setting; the formerallow_experimental_webterminalsetting is deprecated but still honored for backward compatibility. To disable the endpoint, setenable_webterminaltofalse. #106255 (Alexey Milovidov). - PromQL HTTP endpoints now support specifying the database and table via URL query parameters (
database=,table=, ortable=db.table). The previous implicitdefault.prometheustable fallback is removed: if neither the handler config nor the URL specifies a table, the handler now returnsThe time series table name is not set. To keep the old behavior, configure<table>default.prometheus</table>or passtable=...in the URL. #107553 (Vitaly Baranov). - Added support for the PromQL
histogram_quantilefunction inprometheusQueryandprometheusQueryRangetable functions. This enables computing quantiles over classic Prometheus histogram buckets identified by thelelabel. #103477 (Joe Smith). - Added lazy posting list apply mode for the text index. When enabled via
SET allow_experimental_text_index_lazy_apply = 1andSET text_index_posting_list_apply_mode = 'lazy', posting lists are decoded on demand at packed-block granularity using a cursor-based approach instead of being fully materialized into Roaring Bitmaps, reducing memory usage and CPU time for selective text index queries. #100035 (Peng). - Added support for the AssemblyScript ABI for WebAssembly UDFs. You can try the AssemblyScript ABI without installing the toolchain locally by using the browser-based playground, which compiles AssemblyScript code and loads the resulting WebAssembly module into local ClickHouse. #104606 (Vladimir Cherkasov).
- Allow for attaching Prometheus handlers on the main HTTP port with an optional prefix. #104975 (James Cunningham).
- Added an experimental
MergeTreesettingpacked_skip_index_max_bytesthat bundles small skip-index substreams into a singleskp_idx.packedarchive per part, reducing inode pressure when many skip indices are defined on a table. The decision is per substream at write time: substreams whose serialized size stays under the threshold go into the archive, anything larger keeps the standaloneskp_idx_<name>.idx2/.mrk2layout. A single part can mix layouts. Full-text indices are not supported and are always per-file. Default is 0 (packing disabled). #105321 (Raúl Marín). - Support
Buffersserialization for WebAssembly UDFs usingABI BUFFERED_V1, and addwebassembly_udf_enable_fuelas a persisted WASM UDF function setting. #105574 (Antonio Andelic). - Add an experimental
use_reader_executorsetting (default off) that routes reads through a new pipeline-basedReaderExecutorinstead of the legacy chain of read buffers. #106570 (Sema Checherinda). Added observability metrics for the experimentaluse_reader_executorread path, including a modeled read-cost KPI (ReaderExecutorModeledCostMsPerRequestedMiB). #106968 (Sema Checherinda). Introduced theChainedBuffersbuffer behind the experimentaluse_reader_executorread path, with aReaderExecutorChainedBufferBytesmetric. #107210 (Sema Checherinda). - Descending sort order in
MergeTreesorting keys (e.g.ORDER BY (time DESC, key)) is now always supported and no longer requires the experimental settingallow_experimental_reverse_key, which became obsolete. #106440 (Nikita Mikhaylov). Nullable(Tuple(...))is now Beta. Disabled by default, setenable_nullable_tuple_type = 1to use it. #107754 (Nihal Z. Miaji).
Performance Improvement
- Various changes to Keeper that make it around 2x faster overall (better batching, pipelining messages to leader, pipelining log appends). #101757 (Michael Kolupaev).
- Reduce per-query overhead for simple
SELECTqueries (parsing, analysis and planning). For example,SELECT count() FROM hitsfrom a single connection is roughly 50% faster. #104513 (Raúl Marín). - Optimize primary key index analysis for long and high-cardinality primary keys. For a long primary key, the run time of index analysis now mainly depends on the complexity of the query's filter (the key columns it actually uses), not on the length of the primary key — so extending the sorting key has negligible extra overhead on index analysis for queries that filter on only a few of its columns. For a high-cardinality primary key, where ClickHouse keeps only a selective prefix of the key columns in memory and does not load the trailing ones, index analysis now works on just that in-memory prefix instead of the whole key. The optimization is enabled by default and can be turned off with the new setting
use_lightweight_primary_key_index_analysis. Closes #65103. #91836 (Nihal Z. Miaji). - The default x86 build now targets x86-64-v3 (AVX2) instead of x86-64-v2 (SSE4.2). This requires a CPU with AVX2 support (Intel Haswell or later, AMD Excavator or later). If your CPU does not support AVX2, use the
amd64compatbuild which targets plain x86-64. #105019 (Raúl Marín). - Use
ipnsortanddriftsort(stable sorting) — C++ ports of the Rust standard library's sort implementations — for the general-purpose comparison sorts. Speeds upORDER BYon non-numeric columns and stable sorts, and removes a worst case on reverse-sorted input. #106650 (Alexey Milovidov). - New
GROUP BYoptimization for high cardinality evenly distributed keys that scatters rows across threads by hashing the grouping key, so each thread aggregates a disjoint subset of keys without a merge phase. Setenable_sharding_aggregator = 1to enable it. #104233 (Nihal Z. Miaji). - Enable hash table prefetching for string key
GROUP BYqueries, improving high-cardinality string aggregation performance by ~8%. #101007 (Le Zhang). - Reduced peak memory usage when merging partial two-level aggregation results with large aggregate states (e.g.
groupArray), by freeing each bucket's source states incrementally during the merge instead of keeping them all alive until the merge completes. #102330 (Yuri Fedoseev). - Memory representation of
EnumDataTypewas optimized. Memory footprint of tables that haveEnumtype in it can improve up to 10x times forEnumcomponent. Operation time to retrieve name by value(number) is similar or faster. Search by name is slightly slower, but this access direction is less common. #95668 (Ilya Yatsishin). - Add identifier resolution caching to prevent duplicate identifier resolution during query analysis. #88043 (Max Justus Spransy).
- Improve performance of query analysis for queries over tables with many columns: avoid computing column node hashes (which include the whole source table expression) when not needed. Analyzing nested
SELECT *subqueries over a table with ~1200 columns is now about 50 times faster. #106957 (Dmitry Novik). - Sped up query analysis for queries with many or deeply nested function calls by removing a redundant query-tree hash from the function resolution cache. #107516 (Dmitry Novik).
- Fixed long login and query-startup stalls with replicated access storage when many access entities (row policies, roles, quotas, settings profiles) change at once. Each per-entity cache now recomputes once per notification batch instead of once per changed entity, removing quadratic work that could hold the access lock for minutes. #107672 (Azat Khuzhin).
- Share the hash join's
FixedHashMapas the join runtime filter on the probe side. When the build-side hash table is (or can be converted to) aFixedHashMap, it is published as the runtime filter and replaces theSet/BloomFilterthatBuildRuntimeFilterStepwould otherwise install. Controlled by the new settingjoin_runtime_filter_from_fixed_hash_table(defaulttrue). #105640 (Xiaozhe Yu). - Lazy application of selector and replication indexes in case of
JOINfollowed by a selectiveLIMITorTopNor anotherJOIN. To control the number of payload columns for enabling lazy selector indexes use the settingquery_plan_min_columns_for_join_lazy_indexing(0 means the optimization is disabled). To control theLIMITfor which the optimization is applied use the settingquery_plan_max_limit_for_join_lazy_indexing. #106566 (Hechem Selmi). - DP (dynamic programming) JOIN reordering is now allowed with parallel replicas. #105889 (Nikita Taranov).
- Improved query plan when JOIN uses runtime filters (default-on
enable_join_runtime_filters): the join-reorder cost model now sees throughWindowTransform(and other row-preserving plan steps) on the right subtree and uses the underlying row count and per-column NDV instead of falling back to no statistics. #107229 (UnamedRus). - De-virtualize the emission of non-joined rows in RIGHT and FULL join by batching them. #105679 (Hechem Selmi).
- Support packed
keys32andkeys64methods inHashJoin. #107202 (Nikita Taranov). - Support packed
keys32andkeys64methods inSet. #107564 (Nikita Taranov). - More optimal handling of nullable columns in aggregation. #106015 (Nikita Taranov).
- Improve performance of
LIMIT BYqueries. #103349 (Nihal Z. Miaji). - Speed up
ORDER BY ... LIMIT BYqueries by runningLIMIT BYinside each parallel sorted stream duringSortwhenLIMIT BY's columns are a prefix of theORDER BY. This reduces the number of rows flowing through the final sort merge and any downstream pipeline steps. This optimization is controlled by the new settingquery_plan_push_limit_by_into_sort(enabled by default). #104000 (Nihal Z. Miaji). - Speed up
SELECT ... LIMIT N BY <cols>queries when<cols>are a prefix of the table's sorting key, or become one afterWHERE col = constfixes leading columns. With this enabled theMergeTreereads data in primary-key order andLIMIT BYfirst filters in streaming mode with O(1) memory per sorted stream which filters out most of the data, then finally running normalLIMIT BYon reduced data to get the final result. Controlled by the new settingoptimize_limit_by_in_order(enabled by default). #105135 (Nihal Z. Miaji). - Speed up
LIMIT BYqueries on partitionedMergeTreetables by runningLIMIT BYinside each partition's stream in parallel, instead of merging all streams into one before applying the limit. This applies when the partition expression is a deterministic function of theLIMIT BYcolumns, so noLIMIT BYgroup can span two partitions. Controlled by the new settingallow_limit_by_partitions_independently(enabled by default). #105126 (Nihal Z. Miaji). - Speed up
LIMIT BYqueries by removing redundant key expressions: a key that is a deterministic function of the other keys is dropped (e.g.LIMIT 5 BY x, f(x)becomesLIMIT 5 BY x), and an injective function of a key is replaced by its argument (e.g.LIMIT 5 BY toString(x)becomesLIMIT 5 BY x). This evaluates fewer and cheaper expressions per row. Controlled by the new settingsoptimize_limit_by_function_keysandoptimize_injective_functions_in_limit_by, both enabled by default. #106818 (Nihal Z. Miaji). - Speed up sharded aggregation,
grace_hashjoin bucketing, and parallel window partitioning by replacing per-chunk column hashing with a kernel that uses hardware CRC32C. #106538 (Harikrishnan Prabakaran). - Optimize
L1Distance,L2Distance,L2SquaredDistance,LinfDistance, andcosineDistancefor array arguments with multi-target auto-vectorization on x86-64-v4/v3. For non-const array arguments, all of these exceptLpDistance, which usesstd::powwith a runtime exponent, can now use compiler-vectorized kernels. The existing AVX-512 and Sapphire RapidsBFloat16const-argument fast paths forL2DistanceandcosineDistanceare preserved. #101310 (Peng). - Improved performance of the
{Norm}DistanceanddotProductfunctions. #106007 (Nikita Taranov). - Improved performance of the
arrayNormfunction. #106211 (Nikita Taranov). - The performance of
dotProductimproved in some cases. #106210 (Nikita Taranov). - Improved performance of the AVX-512 const-left paths for
L2DistanceandcosineDistanceonArray(Float32),Array(Float64), andArray(BFloat16)when the array length is exactly divisible by the vectorized processing width. #104625 (Sergey Kuznetsov). - Enabled AVX-512 codegen for amd and better codegen for
arrayDistance. #106505 (Nikita Taranov). - Improved performance of the
L2DistanceTransposedandcosineDistanceTransposedfunctions for theQBitdata type. #106701 (Raufs Dunamalijevs). - Improve performance of the
encrypt,decrypt,tryDecrypt,aes_encrypt_mysql, andaes_decrypt_mysqlfunctions by up to an order of magnitude, recovering the performance lost in the BoringSSL to OpenSSL 3.x migration (24.4). #107339 (Konstantin Bogdanov). - Improve performance of the
encrypt,decrypt, andhalfMD5functions by avoiding implicit per-row OpenSSL provider lookups in OpenSSL 3.x. #99105 (Konstantin Bogdanov). - Add SIMD implementation of
SHA1that hashes multiple inputs in parallel using AVX-512, improving throughput. #105459 (Joanna Hulboj). - Added an AArch64 ASIMD/NEON backend for the multi-buffer
MD5implementation. #105563 (Venkata Vineel ). - Squash source blocks before calculating projection during
MATERIALIZE PROJECTIONto reduce the number of temporary projection parts and merge overhead. ~3.4x speedup on a 50M-row table. #100047 (Amos Bird). - Reduced
INSERTlatency forMergeTreetables with skip indices onORDER BYcolumns by avoiding redundant column permutations during part writing (~17% on traces-shaped workloads). #101101 (Amos Bird). - Enabled Arrow's SIMD code paths (NEON on ARM, SSE4.2/AVX2/AVX512 on x86) and used them to speed up decoding of
BYTE_STREAM_SPLIT-encoded ParquetFLOAT/DOUBLEcolumns. #106376 (Raúl Marín). - Improved insertion performance for
LowCardinalitycolumns withbloom_filterindexes. #106410 (Michael Jarrett). - Parallelize blob copies in
DiskObjectStorageTransaction::copyFileusing a per-disk thread pool. #105089 (Asya Shneerson). - Avoid reading file contents when using the
Oneinput format with file-like table functions such asfileands3. #105157 (Yue Ni). - Speed up
clickhousestartup on macOS by about 3x by not exporting dynamic symbols, which the dynamic linker would otherwise process on every launch. #107768 (Raúl Marín). - Speed up filesystem cache loading on startup by avoiding a redundant directory open per cache key. #107414 (Alexey Milovidov).
- Speed up filesystem cache loading on startup by letting directory-listing threads help load cache metadata once listing is finished, instead of leaving half the threads idle. #107416 (Alexey Milovidov).
- Reduced
clickhouseprocess startup overhead by updating the bundled WasmEdge library, which no longer generates a random hash secret in a global initializer at every startup. #107869 (Raúl Marín). - The
MergeTreeprimary key and skip indexes can now prune granules for filters whereifNullorcoalescewraps a condition, such asifNull(key = 0, 0)orcoalesce(key = 0, 0). Such predicates — often emitted by query generators to turn a possibly-NULLcomparison into a definite boolean — were previously opaque to index analysis and could not skip granules. This extends the existingallow_key_condition_coalesce_rewritesetting (enabled by default). Closes #106264. #106272 (Andy Zhao). - Skip index evaluation on
DateTime64types should consume lesser CPU in 26.6. #107707 (Shankar Iyer). - Improved performance of text index analysis in multi-token searches by optimizing handling of rare tokens. #98226 (Anton Popov).
- Use a cache for the posting-list compressed segments of the text index. #106299 (Anton Popov).
- Improved the performance of generic exclusion search for queries that select large consecutive ranges of the table. #93813 (Michael Jarrett).
S3clients with the same endpoint and bucket share a cache, avoiding duplicate region discovery. Closes #92482. #96802 (Andrey Zvonov).- If a query contains a
has(<constant array>, <expr>), the analyzer will transform the node to use a fasterinimplementation if it is feasible to do so. #97341 (Shankar Iyer). - When a new job is scheduled in
ThreadPool, wake the most recently idle worker thread (LIFO) instead of an arbitrary one. This reduces memory fragmentation from per-thread allocator caches. The order in which jobs are processed is not changed. #100177 (Alexey Milovidov). - Improved performance of approximate runtime filters and bloom filter indexes. #100201 (Christoph Viebig).
- Allow
ASOF JOINto use theparallel_hashjoin algorithm, parallelizing the build across distinct equality-key values. PreviouslyASOFwas unconditionally opted out ofparallel_hash. #105375 (Greg Maher). - Avoid reading unbounded inputs for
INTERSECTandEXCEPTqueries when an empty input makes the result known to be empty. #105393 (Yue Ni). - Add
constinitfor variousMemoryTrackerblockers. #105490 (Azat Khuzhin). - Improve performance of
bitmapContainsfor non-UInt64groupBitmapstates by avoiding repeatedrb_maxcalls during range checks. #105960 (Yue Ni). - Faster discontinuous queries for
LowCardinalitycolumns backed by a single dictionary. #103662 (Ivan Babrou). - Added a fast path for the
HashJoinprobe when the block has a single row. #106008 (Nikita Taranov). - Predicates from queries like
SELECT ... FROM view(SELECT ... FROM remote(...)) WHERE ...are now pushed into the query sent to the remote shard. The optimizationallow_push_predicate_ast_for_distributed_subquerieslacked a case for table functions. #105986 (Nikolai Kochetov). - Turn on
enable_join_transitive_predicatesby default. #103724 (Alexander Gololobov). - Added support for functions
multiSearchAny,multiSearchAnyUTF8, andmultiMatchAnyin text indexes. Also improved text index analysis for the functionmatch: now patterns with alternative groups can skip more granules. #106279 (Anton Popov). - Allow filters introduced after the initial PREWHERE selection (predicate pushdown, runtime filters, or explicit PREWHERE plus a WHERE set by the planner) to be merged into the existing PREWHERE on a second optimizer pass instead of staying as a separate Filter step above the
MergeTreeread. #105445 (Yarik Briukhovetskyi). - The
QueryConditionCachenow records individually filtered-out granules even within read batches that partially pass PREWHERE, reducing the number of marks re-read by subsequent queries with the same condition. #105335 (Han Fei). - Added Keeper setting
nuraft_use_bg_thread_for_snapshot_io, enabled by default, to makeNuRaftread snapshot objects from a background thread instead of Raft worker threads. #106285 (Antonio Andelic). - Reduce peak memory usage when applying received snapshots in ClickHouse Keeper with
KeeperMemoryStorage. #105851 (Antonio Andelic). - Route LLVM/JIT allocations to a dedicated jemalloc arena. Reduces RSS fragmentation caused by interleaving long-lived JIT bookkeeping with short-lived query allocations. Adds new asynchronous metrics
jemalloc.jit_arena.active_bytes,jemalloc.jit_arena.dirty_bytes,CompiledExpressionCacheBytesMax, andCompiledExpressionCacheCountMaxfor observability.SYSTEM DROP COMPILED EXPRESSION CACHEnow also drops the underlying CHJIT instances and purges the JIT arena. #104113 (Raúl Marín). - Fix excessive memory reservation when reading sparse dictionary-encoded
Nullable(String)columns fromParquetwith the native V3 reader. #102805 (Francisco). - Fixed
CREATE TABLE ... CLONE AS (and REPLACE / ATTACH PARTITION ... FROM)on encrypted disks copying data instead of hardlinking it. #106731 (Nikita Mikhaylov). - Improve cardinality estimation in the query plan optimizer: a column produced by a deterministic single-argument function (e.g.
toYear(date)) now inherits its argument's number of distinct values as an upper bound instead of being left without statistics, leading to more accurate join reordering. #107757 (Alexander Gololobov). - Reduced CPU overhead of asynchronous logging under high log rates by notifying the log consumer only on the empty-to-non-empty queue transition instead of on every message. #107352 (Nikita Mikhaylov).
- Remove duplicate calculations during query execution in more scenarios. #106113 (Yarik Briukhovetskyi).
- Parallelize the processing of a recursive CTE's result: a
GROUP BYor other operation over a largeWITH RECURSIVEresult is no longer limited to a single thread. #107694 (Alexey Milovidov). - Improved the performance of case-insensitive substring search (
positionCaseInsensitiveUTF8,ILIKE,multiSearchAnyCaseInsensitiveUTF8, and related functions) by adding a NEON SIMD path on ARM and a wider AVX2 kernel on x86. #107882 (Raúl Marín). - Fixed a ~16% throughput regression of the
FPCfloating-point codec on ARM that was introduced when its predictor tables started usingVectorWithMemoryTracking. #108182 (Groene AI).
Improvement
- The background
MemoryWorkernow periodically updates the server's hard memory limit based on the current memory usage and the amount of memory the kernel reports as available, so ClickHouse leaves room for other processes running on the same host. The formula is(resident memory + system MemAvailable) * max_server_memory_usage_to_ram_ratio. The samemax_server_memory_usage_to_ram_ratioserver setting controls both the startup cap and the dynamic adjustment; set it to0to disable both. To keep only the static startup/reload cap (the behavior of previous versions), set the new server settingmemory_worker_dynamic_hard_limitto0. #104964 (Alexey Milovidov). - Support C# PostgreSQL client in
PostgreSQLprotocol. This closes #18611. #80785 (Konstantin Vedernikov). - Mutations now use the analyzer. #98884 (Nikolai Kochetov).
- Added granular control over query echoing in the CLI. The
--echooption now accepts an optional boolean value and works in both interactive and batch mode. New options--echo-formattedand--echo-query-idcontrol whether echoed queries are formatted and whether thequery_idis printed, respectively. The--hilite/--highlightoption now also controls highlighting of echoed queries. As a side effect,--echois now a boolean-value option, so a positional query directly after a bare--echois treated as its value; use--echo --query "..."or--echo=falseinstead. #106191 (Alexey Milovidov). - Support schema evolution together with concurrent consistency checks for data lake catalogs. #106102 (Konstantin Vedernikov).
- Allow cache disk for datalake table engines. #102017 (RinChanNOW).
- Fix
DataLakeCatalogdatabases withcatalog_type = 'onelake'reading table data by using the OneLake Blob endpoint (.blob.fabric.microsoft.com) by default. Setonelake_use_blob_endpoint = falseto keep the previous DFS endpoint (.dfs.fabric.microsoft.com) behavior. #106843 (Konstantin Vedernikov). - Update default of
S3(Azure)Queuesettingpersistent_processing_node_ttl_secondsfrom1 hourto6 hours(which stands for cleanup time due to service unclean restart etc). The previous default was fine for processing nodes ttl, but it is also used for bucket lock ttl, which can be hold for longer time, therefore 1 hour was not enough. #106838 (Kseniia Sumarokova). - Decreased the default size of the
Icebergmetadata cache from 1 GB to 128 MB. #106492 (Konstantin Vedernikov). - Propagate the
S3Queuestreaming taskquery_idto dependent table inserts. #106494 (Christoph Wurm). - Populate
used_storagesinsystem.query_logwith the storage engine name when querying tables viaDataLakeCatalog. #100706 (Melvyn Peignon). - You can check which 'operation' and what 'summary' Iceberg's snapshots have. Useful for testing and debugging. #106246 (Den Kalantaevskii).
- Complete the final
S3multipart upload request asynchronously via the task tracker, so it can overlap with the last part upload instead of running serially in finalize. #105487 (Asya Shneerson). - Added four new
MergeTreetable settings to control default parameters of text indexes:text_index_dictionary_block_size,text_index_dictionary_block_frontcoding_compression,text_index_posting_list_block_size, andtext_index_posting_list_codec. These settings allow tuning text index behavior at the table level without specifying parameters in every index definition. Explicit per-index arguments still take precedence. #100626 (Anton Popov). - Allow projections to override additional
MergeTreesettings (compression, part format, serialization) beyond justindex_granularity, with an allow-list of allowed settings and validation. #101170 (Amos Bird). - Add
current_projection,current_projection_progress,projections_completed, andprojections_remainingcolumns tosystem.mergesto expose projection merge progress. #102611 (Amos Bird). - Fixed
PREWHEREwithINsubquery on primary key columns not using primary key index for granule pruning, causing full table scans instead of reading only relevant granules. #102570 (Nikita Mikhaylov). - Function
h3PolygonToCellsnow enforces the maximum array size across all polygons of aMultiPolygon, validates the underlying H3 library return codes, and rejectsMultiLineStringarguments instead of silently returning an empty result. #106399 (Raúl Marín). - Add a new keeper-only
system.keeper_snapshotstable with information about local ClickHouse Keeper snapshots. #105571 (Miсhael Stetsyuk). - Add a new keeper-only
system.keeper_changelogstable with information about local ClickHouse Keeper changelog (Raft log) files. #105617 (Miсhael Stetsyuk). - Add a keeper-only
system.keeper_clustertable. Contains one row per Raft cluster member as seen by the current Keeper. #105646 (Miсhael Stetsyuk). - Add more Keeper profile (server-side + client-side) events for watches. Closes #97703. #105336 (Konstantin Vedernikov).
- Added Keeper
coordination_settingsforNuRaftuncommitted log entry admission limiting and append-entries backward-probe throttling. #106108 (Antonio Andelic). - Add
enable_compressionsetting for themysqltable function, theMySQLtable engine, theMySQLdatabase engine, dictionarySOURCE(MYSQL), and named collections. When enabled, ClickHouse negotiates MySQL protocol-level compression for all data transferred over the connection. #103229 (Bernard Lim). - Reduced cancellation latency for queries running over the PostgreSQL wire protocol:
KILL QUERYnow interrupts output serialization within a single chunk instead of waiting for the entire chunk to be sent to the client. #106535 (Roman Vasin). - Reduced cancellation latency for queries running over the MySQL wire protocol:
KILL QUERYnow interrupts output serialization within a single chunk instead of waiting for the entire chunk to be sent to the client. #107228 (Roman Vasin). - Fixed reading of the
auth_responselength in the MySQL handshake, where a length byte>= 128was interpreted as a multi-gigabyte value because it was read as a signedchar. #107384 (uwezkhan). MaterializedPostgreSQLnow maps PostgreSQLnumeric(p, 0)columns with precision greater than 76 (e.g.numeric(78, 0)used for 256-bit integers) to ClickHouseInt256instead of failing with "Precision too big". Values that do not fit intoInt256are rejected with a clear error. #107431 (Alexey Milovidov).- Send an exception to the client when TCP connection setup fails. #107317 (Nikolai Kochetov).
- Users can now insert
AvroFixedfields for 8-bit/16-bit/32-bit/64-bit integer variants. #98139 (Patrick Pichler). - The
AvroConfluentformat now retries the Confluent Schema Registry HTTP client on transient failures (transport timeouts, connection refused, DNS errors, HTTP5xx/408/429) with exponential backoff, instead of aborting the INSERT on the first network glitch. New settingsformat_avro_schema_registry_max_retries(default5) andformat_avro_schema_registry_retry_initial_backoff_ms(default100) control the policy. Schema-validation errors (HTTP409, malformed Avro JSON) remain fatal. #106661 (Groene AI). - Record privileges in
system.query_log.used_privilegesfor all granted access checks, including those that go through the non-throwingisGrantedpath (checkAccessWithFilter). Previously only privileges checked via throwing entry points (checkAccess/checkGrantOption) were recorded, which madeREAD ON FILE/READ ON S3/READ ON AZURE/READ ON URLinvisible in the audit log forDESCRIBE,CREATE TABLE AS, and similar queries that usefile/s3/azure/urltable functions. Access enforcement is unchanged. #104693 (Alexey Bakharew). - Added asynchronous metrics
TotalUncompressedBytesOfMergeTreeTablesandTotalUncompressedBytesOfMergeTreeTablesSystem, reporting the total uncompressed size of data stored in MergeTree-family tables. #106364 (Alexey Milovidov). - Adds the
GlobalMemoryLimitExceededprofile event so operators can monitor when the server-wide memory limit is hit. #106466 (Sacheendra Talluri). - Populate the
ExecutableUserDefinedFunction*ProfileEventscounters forexecutable_poolUDFs. Per-call invocation count, wall and pool-wait time, child-process CPU and peak memory, and stdin/stdout bytes are now visible insystem.query_log.ProfileEvents. #105010 (Xu Jia) #105618 (Ilya Andreev). - Added asynchronous metrics
ExecutableUserDefinedFunctionMemoryResidentBytesandExecutableUserDefinedFunctionProcesses, reporting the resident memory (VmRSS) and number of live processes ofexecutableandexecutable_pooluser-defined functions, including descendant processes and idle pool workers. #107300 (Hanzi Jiang). - Added three Linux-only async metrics —
MemoryThreadStacksCount,MemoryThreadStacksVirtual, andMemoryThreadStacksResident— that report pthread stack memory separately from the rest of anonymous memory. Enabled viaasynchronous_metrics_enable_heavy_metrics. Requires Linux 5.17+ (prctl(PR_SET_VMA_ANON_NAME)) and readable/proc/self/smaps; otherwise the metrics are absent and the limitation is reported insystem.warnings. #106230 (Raúl Marín). - Expose the
MemoryThreadStacks*asynchronous metrics (resident/virtual size and count of thread stacks) on macOS. #107752 (Raúl Marín). - Table engines now carry embedded documentation, introspectable via the new
description,syntax,examples,introduced_in, andrelatedcolumns of thesystem.table_enginestable. #106177 (Alexey Milovidov). - Database engines now carry embedded documentation, introspectable via the new
description,syntax,examples,introduced_in, andrelatedcolumns of thesystem.database_enginestable. #106178 (Alexey Milovidov). - Data types now carry embedded documentation, introspectable via the new
description,syntax,examples,introduced_in, andrelatedcolumns of thesystem.data_type_familiestable. #106180 (Alexey Milovidov). - Input/output formats now carry embedded documentation, introspectable via the new
description,examples,introduced_in, andrelatedcolumns of thesystem.formatstable. #106181 (Alexey Milovidov). - Aggregate function combinators now carry embedded documentation, introspectable via the new
description,syntax,examples,introduced_in, andrelatedcolumns of thesystem.aggregate_function_combinatorstable. #106185 (Alexey Milovidov). - Added the
--chimecommand-line option toclickhouse-client,clickhouse-local, and the embedded client. When a query finishes (on success or on error) after running for at least N seconds, the client writes the ASCIIBELcontrol character (\x07) to stderr. Terminals decide whether to make a sound or a visual flash based on the user's preferences. Enabled by default with a 5-second threshold; pass--chime Nfor a custom threshold or--chime 0to disable. Closes #92718. #104545 (Groene AI). - In
clickhouse-client, when the terminal does not support bracketed paste, embedded newlines from a pasted multi-line query are now folded into the same edit buffer instead of switching to the continuation prompt for every line. The pasted query stays under a single prompt and the arrow keys navigate across its lines. This is a best-effort improvement that relies on the typical TTY-buffered paste behavior. #104299 (Alexey Milovidov). Now also works with syntax highlighting disabled (--highlight 0). #106665 (Alexey Milovidov). - Add MySQL-style runtime pager control for
clickhouse-client/clickhouse-local. #105706 (Azat Khuzhin). clickhouse-clientnow respects non-UTF-8 terminals: when the terminal character encoding is not UTF-8 (e.g. withLANG=C), thePrettyformats fall back to ASCII grid borders instead of printing Unicode box-drawing characters that would corrupt the terminal. #106213 (Alexey Milovidov).- Sanitize server-supplied display strings in
clickhouse-client'sHellopacket handling (server name, time zone, display name, password-rule patterns and messages) so a hostile server cannot inject bytes that the client renders verbatim, and cap their size to defend against unbounded allocation. #105243 (Raúl Marín). - The Web UI now displays the result as an image when a query uses an image output format such as
FORMAT PNG, instead of showing the raw bytes as a table. #107638 (Alexey Milovidov). - Add setting
output_format_pretty_use_nbsp_for_paddingto render table-layout padding in table-stylePrettyformats asU+00A0NO-BREAK SPACE whenoutput_format_pretty_grid_charsetisUTF-8. This helps copiedPrettyoutput keep table alignment in tools that collapse regular spaces. The setting is disabled by default, andASCIIcharset output keeps regular spaces. #103559 (Ashrith Bandla). - The universal install script now also installs
clickhousectlinto~/.local/binon Linux and macOS, with achctlsymlink. SetCLICKHOUSE_ONLY=1to skip. #105399 (Alasdair Brown). - Fixed a spurious
Syntax error: Unterminated quoted stringthat could occur intermittently when installing ClickHouse viacurl https://clickhouse.com/ | shwhile aclickhousebinary already existed in the current directory. #106417 (Alexey Milovidov). - Fix the left panel height on the
play.htmlpage when the web terminal is open, so the terminal toggle button at the bottom stays visible. #105087 (Alexey Milovidov). - Avoid selecting the only query in the Web UI after running it. #105711 (Joey Yu).
- The Web SQL UI now expands the query editor when a query is at most 30% taller than the current editor height. #105713 (Joey Yu).
- In the Web UI, lay out the bottom menu icons (Web Terminal and GitHub) horizontally when the left panel is expanded, giving the list of databases and tables more vertical space. #106427 (Alexey Milovidov).
- In the Web UI (
play.html), pressingEscapenow deactivates the currently selected result-table cell. #107777 (Alexey Milovidov). - Improvements to the database panel in the Web SQL UI (Play): a tooltip on the database icon, a button to hide the panel, full-width clickable database/table names, and a fix for the panel width shifting when the scrollbar appears. #108013 (Alexey Milovidov).
- Add a server setting (
min_allocation_size_to_throw_on_memory_limit) to allow any allocation to throwMEMORY_LIMIT_EXCEEDED, this should help with preventing OOMs. #105265 (Azat Khuzhin). - Allow
NONEauthentication for SSH (prevents asking password forno_passwordusers). #105476 (Azat Khuzhin). - Reset the supplementary group list in
clickhouse subefore dropping privileges, matching the behavior of/bin/suandsudo. Previously the dropped process inherited the invoker's supplementary groups. #105247 (Raúl Marín). - Add
BFloat16support for numeric predicate (isFinite,isNaN) functions. #105391 (Mohamed Hussain S). - Reduce memory usage of polygon dictionaries (
polygon_index_cell,polygon_index_each) and makesystem.dictionaries.bytes_allocatedcorrectly reflect the lookup index they build. #105431 (Raúl Marín). - Fixes Kafka table engine consumers that kept using a short poll interval after partition assignment, so they return to the configured
kafka_poll_timeout_msand avoid excessive empty polls, smaller inserted parts, and extra merge overhead after rebalances. #100431 (sugaf1204). - Identify columns by position (instead of by name) when removing unused columns in the query plan. This enables unused-column removal when duplicated column names are present. #100586 (János Benjamin Antal).
- ClickHouse throws a proper exception for attempts to use
table_readonlyfor replicated engines, with better exception handling for DDL queries (andDatabaseReplicated) related to this setting. #100950 (alesapin).OPTIMIZE TABLE ... ON CLUSTERand other DDL no longer hang when the target table hastable_readonly = 1. The setting now throws a new dedicated error codeTABLE_IS_PERMANENTLY_READ_ONLY, whichDDLWorkertreats as non-retriable (distinct from the transientTABLE_IS_READ_ONLYthat arises during temporaryReplicatedMergeTreeZooKeeper disconnects). Thetable_readonlysetting is also now explicitly rejected forReplicatedMergeTree, both at creation and viaALTER MODIFY SETTING. Follow-up to #97652. #105109 (Alexey Milovidov). - Fixed refreshable materialized view refreshes that could fail with
UNKNOWN_TABLEafter the target table had been replaced (for example viaEXCHANGE TABLESor drop-and-recreate): the refresh now resolves the target table by name instead of relying on a stale UUID. #102724 (Seva Potapov). - Added a setting
wait_for_part_commit_in_dependent_materialized_views(defaultfalse). When a materialized view'sSELECTreads back from its own source table (for example via anINNER JOINto the source), the cascade could miss the row currently being inserted, because the inserted part is committed only after the dependent views run. Enabling this setting commits the part before the dependent views are triggered, so they observe the in-flight row, at the cost of less insert parallelism. #105943 (Elmi Ahmadov). - Do not swallow fatal errors (e.g.
MEMORY_LIMIT_EXCEEDED) intryDeserialize. #106808 (Azat Khuzhin). - Check
CREATE TEMPORARY TABLEgrant lazily inInverseDictionaryLookupPass. #107098 (Azat Khuzhin). - Fix an
ILLEGAL_TYPE_OF_ARGUMENTerror for distributed queries withserialize_query_plan = 1that contain a lambda with a constant argument (e.g.arrayMap(t -> t.2, ...)). Constant columns ofActionsDAGINPUTnodes are now preserved during query plan serialization. #107124 (Alexey Milovidov). - Deserialization of the states of the
contingency,cramersV,cramersVBiasCorrected, andtheilsUaggregate functions now validates that the stored counts form a consistent contingency table and throws aCORRUPTED_DATAexception otherwise. Closes #106899. #107185 (Nihal Z. Miaji). - Preserve original error codes for exceptions wrapped in
arrow::Status. #107267 (Azat Khuzhin). - Support
keyed_by_normalized_query_hashfor quotas defined in the static server configuration (users.xml), matching the existingCREATE QUOTA ... KEYED BY normalized_query_hashDDL syntax. #107654 (Alexey Milovidov). - The compatibility setting no longer applies obsolete settings, so it does not mark them as changed or produce obsolete-setting warnings. #107737 (Maxim Orlovsky).
- Async inserts no longer log the full list of
query_ids attrace/debuglevel, which since 26.2 could blow uptext_logon services with heavy async insert traffic. Detailed lines are now attestlevel. #107852 (Sema Checherinda). - Filesystem cache improvement: stop invalidated priority entries from pinning
KeyMetadata. Follow up to #106387. #107903 (Kseniia Sumarokova). FileCachemetrics improvement. #106116 (Kseniia Sumarokova).- Do not print the "Stack trace (when copying this message, always include the lines below):" preamble in exception messages when the stack trace is actually empty. #106524 (Alexey Milovidov).
- Fix a potential overflow in
roundUpToMultiplewhen computing filesystem cache boundary alignment for very large offsets. #92579 (Bharat Nallan). EXPLAIN SYNTAXnow formats operators as function calls consistently in explain output (for exampleplus(1, 2)instead of1 + 2). #94681 (Mohamed Abdelhalim ).- Improved table name hints in error messages: no longer suggests the exact same name, and includes the database name in the suggestion (e.g., "Maybe you meant
other_db.my_table?"). #95116 (Mathuranath Metivier). - Improved error message for unresolved identifiers in queries without a
FROMclause to suggest adding one. #101769 (Yash ). - Add
EXPLAIN PIPELINEoption to compact repeated processor chains. #104662 (Yue Ni). - Fix a heap-buffer-overflow read in syntax-error message construction (
UTF8::computeWidthImplviaparseQuery.cpp) that occurred when the parser had backtracked past the first semicolon / end-of-stream token; release builds were splicing bytes from neighboring heap memory into the displayed error, ASan builds aborted. #105086 (Groene AI). - Make hive partition strategy a default under compatibility setting
file_like_engine_default_partition_strategy. #86746 (Kseniia Sumarokova). - Use a larger (8 MiB) thread stack on macOS to match the Linux default, fixing rare server crashes from stack overflow during JIT compilation. #107033 (Raúl Marín).
- The temporary storage size limit of
clickhouse-localis no longer hard-coded to 1 GiB. The default is raised to 1 TiB and can be configured with themax_temporary_data_on_disk_sizeserver setting. #106689 (Alexey Milovidov). - Add
read-checksumscommand toclickhouse-disks. It reads thechecksums.txtfile of aMergeTreeDataPartand prints it as a human-readable, tab-separated table. #106901 (Asya Shneerson). - Added a
read-bitmapcommand toclickhouse-disks. #107834 (murphy-4o). - Chdig: enable TLS for secure connections (previous leads to either "unknown setting
skip_verify" or "connection reset by peer"). #105864 (Azat Khuzhin). chdigv26.5.1. #105918 (Azat Khuzhin).chdigv26.6.1 -{asynchronous_,}metric_log, query patterns, heatmaps, logs/traces stored on disk (previously it can use >40GiB for 1 hour of traces). #107678 (Azat Khuzhin).- The server config (
programs/server/config.xml) now setskeep_alive_timeoutto 30 (formerly 10), aligning with the actual documented and implemented default. #107779 (Dan Checkoway). - The default for the server setting
disk_connections_rcvbufchanged from0(kernel TCP autotuning) to204800(200 KB), capping the per-socket TCP receive buffer for object-storage (S3/Azure/GCS) disk connections. #107859 (Sema Checherinda). - The
PREWHEREoptimizer now groups conjuncts that reference the same column set before estimating selectivity, so that conditions likea > 2500 AND a < 2502are evaluated together as a combined range rather than as two independent predicates, producing a more accurate selectivity estimate. #106337 (Han Fei). - Add silk fiber aware secure and plain socket implementations. #107680 (Miсhael Stetsyuk).
- Fixed a garbled error message (swapped arguments) and a typo in the
nestedfunction. #108031 (Alexey Milovidov). - Added a
sedcommand toclickhouse-disksthat applies a sed expression to a given path, in-place. #107131 (Asya Shneerson). - Added the create-time
materialized_postgresql_use_extended_date_and_time_typessetting for theMaterializedPostgreSQLdatabase engine. By default (enabled), PostgreSQLdate/timestampcolumns are inferred asDate32/DateTime64; setting it to0atCREATE DATABASEtime infers the narrowerDate/DateTimetypes. #107428 (Alexey Milovidov).
Bug Fix (user-visible misbehavior in an official stable release)
- Make possible to drop detached parts with the
tryNsuffix. #58957 (János Benjamin Antal). - Fix a
MULTIPLE_EXPRESSIONS_FOR_ALIASexception for queries with duplicate projection aliases (for exampleSELECT *, day + 365 AS day) inside nested subqueries when running with parallel replicas. #80310 (Alexey Milovidov). - Fix a bug with
splitMultipartQuerythrowing an "Empty query" error for queries that end with comment after semicolon. #85491 (Yarik Briukhovetskyi). - Fix an exception with
ARRAY JOINs:Function writeSlice expects same column types for GenericArraySlice and GenericArraySinkwhich happens whenLowCardinalitynumeric types are used (issue #57243). #91784 (Jimmy Aguilar Mena). - Fix
NOT_FOUND_COLUMN_IN_BLOCKexception when usingLIMIT BYwith constant columns alongsideDISTINCTandORDER BYwith the new analyzer. #93195 (Ashrith Bandla). - Fix
NOT NULLcolumns being silently created asNullablewhendata_type_default_nullable = 1and the table is created in aReplicateddatabase or viaON CLUSTER. #97572 (xiaohuanlin). - Fixed HiveCatalog connection stability by adding automatic retry mechanism and reconnection logic for handling TTransportException errors when communicating with Hive Metastore. #98471 (Dmitriy Borisenko).
- Fixed
nestedfunction (used internally byARRAY JOIN) strippingLowCardinalityfrom column types, causingArray(LowCardinality(String))to becomeArray(String)in output. Closes #95582. #98974 (Yash ). - Fix "Distributed task iterator is not initialized" exception when using
url,s3, or similar table functions in queries with parallel replicas enabled. #100146 (Alexey Milovidov). - Fix logical error exception when reading Iceberg tables whose format version was upgraded by an external tool (e.g. Spark). #100407 (Alexey Milovidov).
- Functions
like,ilike,notLike,notILike, andmatchnow support constant haystack with non-constant needle (e.g.'foo' LIKE pattern_column), which previously threwILLEGAL_COLUMN. #100479 (Yash ). - Fixed wrong row count returned by a
MaterializedViewquery withquery_plan_enable_optimizations = 0when the view maps an integer column to aBoolcolumn. #100692 (Maksim Moisiuk). - Fix an exception (
LOGICAL_ERROR: 'PREWHERE passed to format that doesn't support it') when reading Iceberg tables containing ORC data files with PREWHERE optimization enabled. #101206 (Groene AI). - Fix race in RestCatalog. #101216 (Smita Kulkarni).
- Fix
NOT_FOUND_COLUMN_IN_BLOCKerror when selecting from a VIEW over a table with a normal projection. #101218 (Amos Bird). - Fix stale metadata in FileLog when a file is deleted and recreated. #101408 (Azat Khuzhin).
- Fix join reordering silently dropping unmatched rows of a
RIGHT/LEFT JOINwhen it is comma-joined (cross) with another table, e.g.t1 RIGHT JOIN t2 ON t1.c = t2.c, t3. The query previously returned the inner-join result instead of the outer-join one. #101684 (Groene AI). - Fixed
FORMATclause being consumed byINSERTinstead of applying toEXPLAINoutput inEXPLAIN INSERT INTO ... SELECT ... FORMAT .... #101772 (Yash ). - Fixed incorrect compression codec selection for
MergeTreeparts when the table-leveldefault_compression_codecsetting was explicitly configured. Parts written on insert, during merges, and for projections used the server-wide default codec instead of the table-level setting (the empty part produced by a fully-deleting mutation is now covered as well). #101784 (Yash ). - Reject negative
Float64values (e.g.-100.5) in workload settings likemax_bytes_per_second,max_cpus, etc. Previously only negative integers were validated, allowing negative floats to silently create broken scheduler nodes. Closes #101825. #101842 (Groene AI). - Fix a
LOGICAL_ERROR("Port is not connected", code 49) that could occur when executing queries involving a VIEW with aggregation inside a JOIN. #102574 (Jimmy Aguilar Mena). - Fix inconsistent part metadata after mutations of columns with non-default serializations. #102817 (Eduard Karacharov).
- Fix updating metadata before executing mutation resolves #96806. #102882 (Smita Kulkarni).
- Fix SELECT queries being significantly slower when concurrent INSERTs are running. Previously an INSERT pipeline reserved CPU slots up to
max_threadsat query start even when most slots were never used, starving concurrent SELECTs. CPU slot allocation is now demand-driven: the pipeline only requests slots as it actually pushes parallelizable work. Applies both to concurrency control and to the preemptive CPU scheduler for workloads. New server settingconcurrent_threads_lazy_allocation(defaulttrue) acts as a rollback lever. #102928 (Seva Potapov). - Fix
NULLpropagation when reading subcolumns extracted fromNullable(Tuple(...))columns. For example, fortup Nullable(Tuple(s Nullable(String))),SELECT tup.snow correctly returnsNULLin rows where the outer tuple isNULLinstead of garbage values. This covers all element types that can representNULL:Nullable,Dynamic,VariantandLowCardinality(Nullable(...)). Closes #105356. #102942 (Nihal Z. Miaji). - Throw
INCORRECT_DATAinstead ofLOGICAL_ERRORwhen client-supplied data in the Native format is truncated or malformed. #102975 (János Benjamin Antal). - Added cancellation check to ObjectStorage read operation. Closes #98165. #103016 (Smita Kulkarni).
- Respect
input_format_binary_max_type_complexityin decoding aggregate function parameters. Closes #102903. #103026 (Pavel Kruglov). - Fix nullable inference for geo columns in Arrow-based Parquet reader. Closes #101845. #103032 (Pavel Kruglov).
- Fixed
recursiveRemoveLowCardinalityerasing custom geometry type names (e.g.LineStringvsRing,MultiLineStringvsPolygon), which caused misinterpretation of the geometry type. Closes #103207. #103041 (Joanna Hulboj). - Fixed
input_format_max_block_size_bytesbeing silently ignored duringINSERTparsing whenmax_insert_block_size_bytesis0(the default). The setting now correctly limits the size of blocks produced by row input formats. #103068 (Kirill Kopnev). - Fixed ClickHouse occasionally producing invalid GSSAPI tokens due to incorrect stripping of trailing null bytes. #103114 (Michael Jarrett).
- Fix analyzer-time constant folding for short-circuit functions (
if,multiIf,and,or, etc.) so that statically unreachable branches no longer raise exceptions at analysis time. For example,WITH 0 AS n SELECT multiIf(n = 0, 0, intDiv(100, n))now correctly returns0instead of failing with a division-by-zero error. #103157 (Peng). EXPLAIN SYNTAXexpands parameterized views. #103263 (Jordi Villar).- Fix data corruption when writing Parquet (and other trailer-bearing formats such as ORC and Arrow) to HDFS via
INSERT INTO FUNCTION hdfs(...). Since 26.1,WriteBufferFromHDFSdid not flush its working buffer onfinalize(), so the last up toDBMS_DEFAULT_BUFFER_SIZEbytes of every file were silently lost, including the ParquetPAR1footer. Reading such files returnedNot a Parquet file (wrong magic bytes at the end of file). #103268 (Groene AI). - Fix wrong results and a possible logical error for correlated subqueries when a join size limit (
max_rows_in_join/max_bytes_in_join) is set together withjoin_overflow_mode = 'break'. The join created internally to evaluate a correlated subquery now ignores those user limits, so it can no longer stop early and drop rows. #103322 (Groene AI). - Fix a bug where
ALTER TABLE ... MODIFY SETTINGon anEmbeddedRocksDBtable could persist an invalid setting value to the table metadata file even when the server rejected the query. On the next server restart the table would fail to attach withCANNOT_PARSE_BOOL(or a similar parsing error), and in databases where load failures are fatal the server would refuse to start. Invalid setting values are now rejected before any metadata is written. #103417 (Groene AI). - Fixed a server abort when creating a table with an object-storage engine (
AzureBlobStorage,DeltaLakeAzure,S3,HDFS) using an unsupported number of arguments. The server now returns a cleanNUMBER_OF_ARGUMENTS_DOESNT_MATCHerror instead of aborting in debug/sanitizer builds. #103544 (Groene AI). - Fix a server crash in
JSONandDynamicdata type parameter parsing when the abstract syntax tree (AST) was structurally malformed (for example produced by the AST fuzzer): theequals(name, value)parameter expression could be left with fewer than two children, whichDataTypeObjectandDataTypeDynamicthen dereferenced without bounds checking. #103545 (Groene AI). - Fix logical errors in analyzer with column names collision in lambda used in prewhere. Closes #103584. #103627 (Pavel Kruglov).
- Fix sporadic
Logical error: 'Database <name> not found'fromDataLakeConfiguration::getCatalogwhen anIcebergengine table is loaded inside a regular database during async metadata loading. #103775 (Groene AI). - Fix
MULTIPLE_EXPRESSIONS_FOR_ALIASerrors thrown by remote replicas when running queries that reference projection aliases insidePREWHERE/WHERE/HAVING/QUALIFY(e.g.SELECT x AS a, y AS b, (a AND b) AS c FROM t PREWHERE c) orSELECT *over self-joins with overlapping column names, with parallel replicas andparallel_replicas_local_plan = 0. Closes #74324. #103806 (Groene AI). - Fix server abort when a query uses nested
coalesce/ifNullcomparisons (e.g.WHERE coalesce(a, b, coalesce(c, d), e) = const) on aMergeTreetable with multipleminmaxskip indexes anduse_skip_indexes_for_disjunctions = 1. The skip-index rewrite of<op>(coalesce(...), const)is now applied recursively to inner coalesce arguments, so the per-indexKeyConditionRPN matches the template's RPN as the disjunction-tracking code already assumes. #103929 (Groene AI). - Fix
max_rows_to_transferandmax_bytes_to_transferbeing silently ignored forGLOBAL INandGLOBAL JOINqueries under the new analyzer. The settings now raiseSET_SIZE_LIMIT_EXCEEDED(or break, depending ontransfer_overflow_mode) when the materialised external table exceeds the configured limit, matching the behavior of the old analyzer. Closes #103333. #104119 (Groene AI). - Fix excessive catalog/S3 metadata reads when an INSERT or DDL statement references a non-existent table in a DataLake catalog database with
show_data_lake_catalogs_in_system_tablesenabled. The typo-hint suggestion path loaded full per-table Iceberg metadata for the whole catalog, which could exhaust memory on large catalogs. #104124 (DQ). - Fix a crash (
LOGICAL_ERROR"Columns are assumed to be of identical types, but they are different in Nullable" in debug builds, aColumnString::compareAtnull-pointer SIGSEGV in release builds) and a wrong result that could occur in queries usingdirectjoin_algorithmwith aMergeTreeright-side table when the lookup plan reordered columns during optimization. The right-side columns could land in wrong-named slots, so a filter or comparison on the join key saw a column of the wrong type. Surfaced by AST fuzzer as STID 2139-5111 and reported in #107272. #104174 (Groene AI). - Reject out-of-range integer partition ID for
Dateinstead of silent overflow orLOGICAL_ERRORonALTER. #104250 (Azat Khuzhin). - Disable
additional_table_filterswith parallel replicas and the analyzer without query plan serialization. Previously it could lead to incorrect results. #104296 (Azat Khuzhin). - Fix
dictGetOrNullsilently overwriting other columns in theSELECTprojection withNULLwhen called with aNullablekey column whose values are missing in the dictionary. The function was mutating an input-aliased null map in place; it now deep-clones the result column before mutation. Closes #73633. #104327 (Groene AI). - Fix a broken patch part after
ALTER TABLE ... DROP PARTITION ID 'patch-...'followed byDETACH/ATTACH TABLE. Previously the empty covering part was written withoutpartition.datandsource_parts.dat, leading to abroken-on-start_patch-...entry insystem.detached_partsafter the next attach or server restart. Closes #93132. Closes #102103. #104353 (Groene AI). - Fixed streaming
INSERTwithinput_format_max_block_wait_msfor theHTTPinterface and forINSERT SELECT FROM input, so partial input blocks are flushed before the request finishes. #104534 (Alexey Milovidov). - Fixed a bug where queries combining
arrayJoinwithORDER BY ... LIMITafter aJOINcould silently return zero rows. The query plan optimization that lifts function evaluation above theSortingStepno longer applies when the lifted expression containsarrayJoin, sincearrayJoincan change the number of rows. Closes #82279. #104558 (Groene AI). - Fix a rare server abort during
MergeTreefamily table destruction. The abort could occur whenshutdownraised an exception before the background-job scheduler was fully stopped: a background task firing in that narrow window would dispatch a virtual call through a partially-destroyed storage object and hit__cxa_pure_virtual. #104561 (Groene AI). - Fix inconsistent result in
JSONcombined subcolumn with a type hint containing null value. #104584 (Pavel Kruglov). - Fix wrong results or missed projection when an aggregate projection contains multiple
sumIfaggregates with differentIN (...)conditions. #104765 (Jimmy Aguilar Mena). - Fix wrong row count from
arrayJoin()used insideJOIN ON: the result was multiplied by the array length an extra time. #104785 (Shaohua Wang). - Fix
deltaSumTimestampreturning wrong results for signed integer types crossing zero. Resolves #104750. #104830 (Konstantin Bogdanov). - Fix block structure mismatch in UnionStep after filter push-down with NULL constants. Closes #104821. #104853 (Pavel Kruglov).
- Fix
Logical error: 'Metadata is not initialized'raised byDELETE FROMon a freshly-attachedIceberg,DeltaLake, orHuditable whose metadata file is corrupted or unloadable. A regular user-facing exception is reported instead, and the server keeps running. Closes #104891. #104917 (Groene AI). - Fixed the
max_memory_usage_soft_limitwas not updated on-the-fly when the configuration changed. The soft memory limit was calculated once at startup and cached, so subsequent config reloads had no effect. After this fix, the limit is recalculated and applied immediately on every config reload, no Keeper restart required. #104940 (Kai Zhu). - Fix JIT symbol resolution on macOS so that sort, expression, and aggregate JIT compilation no longer fail with
CANNOT_COMPILE_CODE: Could not find symbol _<name>. #104946 (Alexei Fedotov). - Fix an exception (
Received signal 6 (abort)in vector hardening, observable asTuple::back()on an empty vector) when executing a query of the formSELECT ... FROM <Distributed table> WHERE/HAVING/GROUP BY ... (sharding_key_column IN tuple())withoptimize_skip_unused_shards_rewrite_inenabled under the new analyzer. #104966 (Alexey Milovidov). - Fix a
Logical error: 'Inconsistent AST formatting'server abort (STID 1941-1bfa) on queries likeCREATE TABLE t (c0 Int CODEC(not((not(materialize(1), materialize(2)))), ZSTD)) ENGINE = Memoryin debug / sanitiser builds. The formatter no longer emits redundant outer parens around a multi-argumenttuple(...)function call that appears insideCODEC/STATISTICS/BACKUP_NAMEargument lists (where the operator form(a, b)is disabled), keeping the format-parse-format round-trip stable. #104991 (Groene AI). - Fix
NOT_FOUND_COLUMN_IN_BLOCKthrown byALTER TABLE ... MATERIALIZE INDEXon parts that were created in 25.8 and contain a skip index over a column that was added with a separateALTER TABLE ... ADD COLUMN. The mutation now correctly reads every column required by every pre-existing skip index and projection on the part during force-recalculation. Closes #104872. #105039 (Groene AI). - Fixed two
LOGICAL_ERROR: Reading from materialized CTE 'X' before it has been materializedshapes thrown by queries withenable_materialized_cte: (1) a reused materialized CTE filtered byIN (subquery)over another materialized CTE, and (2) a materialized CTE referenced both directly and inside aWHERE ... IN (...)filter that hits a MergeTree primary key through a nested IN-subquery.EXPLAINon the same queries was affected too because the bugs fired during plan optimization. Closes #101940, closes #102320. #105041 (Dmitry Novik). - Fix
countminstatisticsPREWHEREselectivity estimation forFloat32columns. Two bugs causedcountminstatistics to silently produce wrong estimates forFloat32columns:ConditionSelectivityEstimatorskipped statistics entirely when the column type (Float32) was narrower than the literal type (Float64), falling back to default selectivity and ignoring the sketch; andStatisticsCountMinSketch::estimateEqualhashed the first N bytes of aFieldobject, butFieldstoresFloat32asFloat64(NearestFieldType<Float32>=Float64), so the byte pattern used at query time differed from the actualFloat32bytes stored during build. #105047 (Han Fei). ATTACH TABLE name <clauses>;queries that supply storage clauses (ORDER BY,PARTITION BY,PRIMARY KEY,SAMPLE BY,TTL,UNIQUE KEY, or engineSETTINGS) without anENGINEnow throwBAD_ARGUMENTSinstead of silently re-attaching the table with its stored definition and discarding the user-supplied clauses. Query-level sessionSETTINGS(such aslog_comment) are still applied. UseATTACH TABLE t;to re-attach with stored metadata, orALTER TABLE t MODIFY SETTING ...afterATTACHto change settings. #105068 (Groene AI).- Fixes a use-after-free in
runningAccumulatewhen called on a column whose aggregate function returns its own state (e.g.uniqStateOrDefaultState,sumStateOrDefaultState,uniqStateForEachState). #105085 (János Benjamin Antal). - Fixed a bug in the Web UI (
play.html): running a query while the cursor was past the only trailing;reported "empty query" instead of running the query. #105107 (Alexey Milovidov). - Fix
LOGICAL_ERROR: 'No user in current context, it's a bug'when aCREATE TABLE ... AS SELECTinside aReplicateddatabase reads fromsystem.current_rolesorsystem.enabled_roles. The query now succeeds and returns an empty result set in this internal DDL worker context. #105150 (Groene AI). - Fixed
ILLEGAL_TYPE_OF_ARGUMENTwhen mergingquantileExactWeightedInterpolated,quantileDD, orquantilePrometheusHistogramaggregate states with their pluralquantilesXxxMergecounterparts (and vice versa). The singular and plural variants of these three quantile families share the same internal aggregate state but were not listed in the internal name-mapping table, so cross-function state merge — and the function-fusion optimization for these families — were rejected. #105189 (Groene AI). - Fix incorrect results of
toStartOfWeek,toLastDayOfWeek,toMonday,toStartOfMonth,toLastDayOfMonth,toStartOfQuarterandtoStartOfYearforDate32andDateTime64arguments whose result falls outside theDaterange: instead of overflowing into arbitrary dates, results before1970-01-01are now clamped to1970-01-01and results after2149-06-06are clamped to2149-06-06. This also fixes wrong query results (incorrectly pruned parts and granules) when such functions were used inWHEREover aDate32orDateTime64key containing out-of-range values. #105244 (Yarik Briukhovetskyi). - Fix a logical error in
arrayRemovewhen the first argument is an array ofVariantwhose alternatives are all incompatible with the type of the second argument andvariant_throw_on_type_mismatchis disabled. The function now treats the comparison as "never equal" and returns the array unchanged instead of triggering a server-sideassertTypeEqualityfailure. #105248 (Groene AI). - Query can be executed successfully even if
FileCachefails to create some directory on disk for caching. #105250 (Den Kalantaevskii). - Fix server abort with
Assertion 'px != 0' failedinExtremesTransformwhen a query withextremes = 1hits an exception (for exampleMEMORY_LIMIT_EXCEEDED) while the transform is building its extremes columns from the first chunk. The client now receives the original exception instead of crashing the server. #105264 (Groene AI). LEFT ANTI JOINnow correctly returns the right-side join key column with default values for unmatched rows, instead of duplicating the left key value. Previously,SELECT a.x AS l, b.x AS r FROM a LEFT ANTI JOIN b ON a.x = b.xcould returnr = a.xfor the unmatched rows when it should return the default (0forInt32,''forString,NULLforNullable). Only the join key column was affected; non-key right columns were already defaulted correctly. The same bug appeared inRIGHT ANTI JOINwhenever the optimizer swapped sides. Closes #99959. #105278 (Groene AI).- Fix data loss in
clickhouse-localwhen started repeatedly with a non-default--default_database(for exampleclickhouse-local --path X -- --default_database=mydb): the lookup for the persisted database UUID was hardcoded tometadata/default, so each restart minted a fresh UUID and the previous run's tables became invisible. Closes #101831. #105284 (Groene AI). - Fix a logical error
Mutation ofMemorytable produced incomplete outputraised when runningALTER TABLE <memory_table> APPLY PATCHESorALTER TABLE <memory_table> APPLY DELETED MASK.Memorytables do not own patch parts or deletion masks, so both commands are now correctly treated as no-ops. #105286 (Groene AI). - Fix long-running queries with Unity Catalog by passing a
table_idparameter in the query request. #105303 (Konstantin Vedernikov). - Fix
CANNOT_CONVERT_TYPEforMergeoverMergeoverDistributedwithdistributed_group_by_no_merge=1. #105330 (Azat Khuzhin). - Fix
clickhouse localandclickhouse clientsilently ignoring--query/-qwhen a positional file argument was also given. Both forms now produceBAD_ARGUMENTSconsistently. #105334 (Raúl Marín). - Fix
REPLACE TEMPORARY TABLEsilently creating a new table when the target didn't exist. It now throwsUNKNOWN_TABLE, matchingREPLACE TABLEsemantics. UseCREATE OR REPLACE TEMPORARY TABLEto keep the create-or-replace behavior. #105373 (Groene AI). - Fixed long-running reads (e.g.
INSERT ... SELECT) from aDataLakeCatalogdatabase withcatalog_type = 'glue'failing with anExpiredTokenerror once the STS session credentials captured at table-metadata load time crossed their expiry. The AWS STS credentials are now refreshed mid-query, so such reads continue past the token's expiry. #105381 (Pratima Patel). - Fix logical error in negative
LIMIT BYin some cases when used withARRAY JOIN. #105403 (Nihal Z. Miaji). - Fix inflated
read_bytes(and the derived bytes/s shown insystem.query_log, progress bar, etc.) when reading Parquet files. The previous implementation reported the row group's total compressed size on every chunk, so reading K of N columns overcounted byN / K. It is now summed only across the selected columns. Also fixes file-level progress tracking for Iceberg tables, which previously never reported the data file size. #105413 (Groene AI). - Fixed a possible server segfault in cluster table functions (
s3Cluster,urlCluster,fileCluster, ...) when the planner produces aSELECTwith therecursive_withflag set but noWITHexpression. Closes #105370. #105433 (Groene AI). - Fix wrong result of
countDistinct/uniqExactonNullablecolumns whencount_distinct_optimization = 1(the NULL group was incorrectly counted). #105439 (Raúl Marín). - Fixed a heap-buffer-overflow when reading Arrow or ArrowStream files with corrupted intermediate offsets in a binary or string column, and a null-pointer dereference when reading geo-tagged Arrow columns. #105449 (Raúl Marín).
- Validate
Dynamic/Varianttypes in windowPARTITION BY, it was not checked before whenallow_suspicious_types_in_group_byis disabled. Closes #105028. #105450 (Pavel Kruglov). - Fix
input_format_json_empty_as_defaultnot working in JSONStrings* formats. Closes #104913. #105453 (Pavel Kruglov). - Fix
NULLinsert intoVariantcolumn viaVALUESformat during expression parsing. Closes #104909. #105455 (Pavel Kruglov). - Fix
dictGetOrDefaultthrowingCANNOT_INSERT_NULL_IN_ORDINARY_COLUMNwhen the default argument is aNullableexpression andshort_circuit_function_evaluationis enabled with a mix of found and not-found dictionary keys. #105461 (Raúl Marín). - Fix silent value truncation in
Dynamiccolumns when theQuoted(Values) text reader falls back toStringfor incomplete inferred types likeMap(Array(Nothing), ...). Previously the fallback wrapped the raw field with naive'...'concatenation, so an inner single quote (always present for such fallbacks) prematurely terminated the quoted string and the rest of the value was lost. #105463 (Groene AI). - Fix SIGSEGV when reading
Dynamicsubcolumns from compressedMemorytable afterALTER. Closes #104901. #105464 (Pavel Kruglov). - Fix
toFloat64/toUInt32/toString/etc. onDynamicignoringcast_keep_nullable. Closes #104789. #105467 (Pavel Kruglov). - Include
skip_first_linesin schema cache key forWithNamesformats. Closes #104527. #105469 (Pavel Kruglov). - Fix a server segfault in
uniqStateOrNull/uniqStateOrDefault/uniqOrNullState(and similar combinator chains overuniq) when used withGROUP BY ... WITH ROLLUP,WITH CUBE, orWITH TOTALSand a Nullable argument. #105470 (Groene AI). - Fix
NOT_FOUND_COLUMN_IN_BLOCKexception when combiningORDER BY ... WITH FILL INTERPOLATEandLIMIT N BYwith the analyzer enabled. Closes #103474. #105481 (Yakov Olkhovskiy). - Fix
toStartOfMillisecondandtoStartOfMicrosecondreturning a result off by nearly a second for negative (pre-epoch)DateTime64values, and fixUndefinedBehaviorSanitizersigned-integer-overflow intoStartOfSecond,toStartOfMillisecond, andtoStartOfMicrosecondforDateTime64inputs nearINT64_MIN. #105482 (Groene AI). - Add a new compatibility setting
analyzer_compatibility_prefer_alias_over_subcolumn(disabled by default). When enabled, the new analyzer prefers the alias-prefix interpretation overTuple-subcolumn / dotted-column matches for multi-part identifiers, restoring the previous interpreter's behavior. This avoidsAMBIGUOUS_IDENTIFIER(and related) errors when a query joins a table whose name matches an inner table of a CTE/subquery that usesSELECT *over a join, where asterisk-renamed columns (e.g.b.id) would otherwise leak the inner table identifiers into the outer scope. #105491 (Vladimir Cherkasov). - A vector search query executed with the index only optimization now returns the correct value for
L2Distance()if it is in theSELECTlist. The function was incorrectly returning the L2-squared distance value. Note that the vector search query was returning the correctly ranked results, only applications explicitly retrieving and interpreting theL2Distance()value would have seen the squared value. #105495 (Shankar Iyer). - Fixed a rare issue in new Kafka table engine where messages could be incorrectly handled during topic partition reassignment, potentially leading to skipped messages after offset rollback. #105500 (János Benjamin Antal).
- Fix an exception (
Trying to execute PLACEHOLDER actionlogical error) when aMATERIALIZEDCTE whose body is a correlated subquery is used as the right-hand side ofIN. Such a CTE is now rejected at analysis time, consistent with how the same pattern is already rejected when the CTE is referenced directly inFROM. #105518 (Groene AI). - Fix stdout/stdin compression not applied when format is explicitly specified. Closes #104441. #105528 (Pavel Kruglov).
- Fix SEGFAULT in
singleValueOrNulldeserialization forJSONtype. Closes #103630. #105535 (Pavel Kruglov). - Fix
clickhouse-format --backslashsilently droppingINSERTVALUESdata. Closes #103533. #105536 (Pavel Kruglov). - Fix
variant_throw_on_type_mismatch/dynamic_throw_on_type_mismatch=falsenot catching exceptions during function execution. Closes #103484. #105543 (Pavel Kruglov). - Fix ignoring
input_format_try_infer_datetimesduring insertion into shared data inJSON. Closes #103221. #105544 (Pavel Kruglov). - Fix
histogramproducing wrong results for small unsorted inputs. Closes #103109. #105548 (Pavel Kruglov). - Fix
DateTimewrapping around for out-of-range values inJSONExtractand text deserializations. Closes #103094. #105551 (Pavel Kruglov). - Fix usage of insertion table in table functions when
optimize_trivial_insert_selectis enabled. Closes #103083. #105555 (Pavel Kruglov). - Fix
CASEexpression returning theELSEbranch instead of the matchingTHENwhen both the expression and aWHENvalue wereNULL. #105556 (Raúl Marín). - Fixed a crash in
replxxcaused by hitting theFD_SETSIZElimitation ofselect(now replaced withpoll). Previously, with SSH or the web terminal enabled, this could crash the server. #105559 (Azat Khuzhin). - Materialize subcolumns in
executePartitionByExpressionbefore executing expression. Closes #103057. #105573 (Pavel Kruglov). - Fix
NOT_FOUND_COLUMN_IN_BLOCKexception whenTTLexpression references a subcolumn. #105578 (Pavel Kruglov). - Fix a server crash (SIGSEGV) reachable by any user with
CREATE TABLErights when sendingCREATE TABLE ... TO INNER UUID '...'without anENGINEclause over HTTP or the native protocol. The same bug also crashed the client. The parser now reports a properBAD_ARGUMENTSerror instead of dereferencing a null pointer. #105579 (Groene AI). - Fix
estimateCompressionRatiowindow function losing accumulated data between rows. Closes #101738. #105581 (Pavel Kruglov). - Fix crash when inserting tuples of different sizes in the same VALUES clause into a
Stringcolumn. Closes #101727. #105582 (Pavel Kruglov). - Hive partition value extraction now honors the
cast_string_to_date_time_modesetting and accepts ISO 8601 timestamps with timezone suffixes (e.g.+0000,+00:00,Z) in partition keys by default. #105584 (Alexey Milovidov). - Fixes
NOT_IMPLEMENTEDerror ontoStringfromDateTimewith Timezone containingNULLvalue. Closes #103712. #105587 (Yarik Briukhovetskyi). - Fix OOB read in flattened
DynamiccolumnNativedeserialization. #105666 (Pavel Kruglov). - Fix a
LOGICAL_ERROR(Unexpected return type from if) raised during query planning forifexpressions whose result type isVariantand whose second-or-third branch is a constant-conditionifover aUInt64literal that fits intoInt64. Closes #105649. #105680 (Groene AI). - Fix wrong results when reading an Iceberg table with
iceberg_use_version_hint = 1after another writer (such as theicebergLocal/icebergS3table function) without the setting advances the table.version-hint.textis now kept in sync by every writer once the file exists, so subsequent readers using the hint see the latest snapshot. #105682 (Groene AI). - Fixed a silent under-count in
SELECTqueries whenuse_query_condition_cache = 1(default). A query of the shapePREWHERE pk_prefix = X WHERE non_pk IN (...)against a column with a bloom-filter skip index poisoned theQueryConditionCachefor thepk_prefix = Xpredicate, so a subsequent benignSELECT count() ... WHERE pk_prefix = Xreturned an incorrect, under-counted result. Affected all 26.x releases. #104781. #105686 (Groene AI). - Fixed
singleValueOrNullMergereturning a concrete value instead ofNULLwhen merging a state that had already observed multiple distinct values. #105734 (Minh Vu). - Fix
Templateinput format error recovery after malformed rows. #105735 (Yue Ni). - Fix a crash in the
mongodbtable function, MongoDB storage and MongoDB dictionary source when the collection name is empty or contains NUL bytes. #105776 (Raúl Marín). - Fix
Keepersnapshot cleanup after failed writes so partial snapshots are cleaned up safely and failed writes can be retried without advancinglatest_snapshot_meta. #105779 (Antonio Andelic). - Fix
ALTER TABLE ... CLEAR COLUMNbeing rejected for explicitSummingMergeTreeandCoalescingMergeTreecolumns_to_sumcolumns. #105785 (Antonio Andelic). - Fixed an assertion in
DatabaseCatalog::tryGetDatabase(and resultingUNKNOWN_DATABASEerror in release builds) when creating a parameterized view whose database name is supplied via a query parameter, for exampleCREATE VIEW {db:Identifier}.v AS SELECT {p:UInt64}. Parameters in the DDL parts of theCREATEstatement are now substituted at create time, while parameters in the SELECT body remain available for substitution at view-call time. #105799 (Groene AI). - Fix
Bad get: has Decimal32, requested Decimal128fromsumMapandsumMapWithOverflowover aNested(... Nullable(Decimal(P, S)))column when the aggregate state is serialised (e.g. parallel replicas,sumMapStatevia a binary-state formatter, external aggregation). #105816 (Groene AI). - Fix
Expected ColumnLowCardinality, got String/Bad cast from type DB::ColumnString to DB::ColumnLowCardinalityerrors whenapply_mutations_on_fly = 1is used on a table with pending on-flyUPDATE/DELETEmutations queued before anALTER MODIFY COLUMN ... LowCardinality(...)mutation. #105847 (Raúl Marín). - Iceberg writes now preserve NULL values in
Nullable(T)partition columns. Previously, a NULL written by ClickHouse showed up as the default value of the inner type (0forint) when read back by Spark or other Iceberg readers. Closes #105852. #105862 (Groene AI). - Fixed
ParquetandORCfilter pushdown forIN (subquery)predicates, allowing row-group/page/bloom-filter pruning to work forfile,url,s3, and object-storage reads. #105863 (Arsen Muk). - Fix read-in-order for
Mergetables (with a new analyzer). #105867 (Nikolai Kochetov). - Fixed Iceberg v2 merge-on-read position deletes returning wrong rows when a single delete file references multiple data files and several such delete files apply to the same data file. The streaming reader (
use_roaring_bitmap_iceberg_positional_deletes = 0) now filters delete-file rows byfile_pathin C++ instead of relying on Parquet row-group pruning, restoring the ascending-positions invariant. #105888 (Groene AI). - Fix
Cannot find columnerror for distributed queries withIN Array(...)filter for the new analyzer. #105894 (Nikolai Kochetov). - Fix a SIGSEGV in
ALTER TABLE ... MODIFY COLUMN ... Nullable(...)onMergeTreetables when a column withSTATISTICSis concurrently dropped by anotherALTER. Closes #105912. #105917 (Groene AI). - Fixed a server crash that could occur when a query reading from PostgreSQL — via the postgresql table function, the PostgreSQL table engine, or a dictionary with a PostgreSQL source — was cancelled (for example with KILL QUERY) and cancelling the remote PostgreSQL query failed. #105949 (Rory Shanks).
- Fix
SYSTEM INSTRUMENT ADDformatting so handler arguments are separated by a single space, and reject invalidSLEEPinstrumentation argument lists with more than two values or a range where the minimum is greater than the maximum. #105984 (Pablo Marcos). - Fix possibly wrong results for queries that combine an outer join with a subsequent inner join referencing the outer join's null-supplying side. Join reordering could pick a plan that pulled inner-join conditions into the outer join's ON clause. #105992 (Vladimir Cherkasov).
- Fixed a possible crash due to a too-large string literal sent within the query. #105996 (Nikita Taranov).
- Fix
INVALID_WITH_FILL_EXPRESSIONexception when usingINTERPOLATE ()(empty) with a sorting prefix inORDER BYanduse_with_fill_by_sorting_prefixenabled. Sorting prefix columns are now correctly excluded from the implicit interpolation set, matching the behavior of explicitly namedINTERPOLATE (col). #106001 (Yakov Olkhovskiy). - Fix
ALTER TABLEpartition operations silently failing forBoolpartition keys. Closes #101722. #106004 (Pavel Kruglov). - Fix
JSONExtractRawandJSONHasfor typedJSONpaths with default values. Closes #101721. #106005 (Pavel Kruglov). - Fix incorrect '/'-prefix addition on empty basepaths in data lake configurations. Closes #105989. #106013 (thewisenerd).
- Fix
IcebergLocaltable engine becoming read-only after aDETACH+ATTACHcycle or a server restart, which made every subsequentINSERTfail withLocal object storage Local is readonly. (READONLY). #106016 (Groene AI). - Fix
Keeperfailures during follower catch-up when the new request dispatcher response queue could fill before the response thread started. #106049 (Antonio Andelic). - Better compatibility with the old analyzer. If the table has columns like
x.a Array, x.b Array, x String, prefer arrays forARRAY JOIN x. #106069 (Nikolai Kochetov). - Fixed the filesystem cache being silently disabled for Azure Blob Storage (e.g. Delta Lake tables over Azure) because object metadata did not include the blob ETag. #106091 (thewisenerd).
- Fix
system.dictionariesreturning 0 rows with partialSHOW DICTIONARIESrevoke. #106105 (Pavel Kruglov). - Fixed a server crash when querying DeltaLake tables with
allow_experimental_delta_kernel_rsenabled and a credential or option that contained invalid bytes (the Rust FFI panicked across theextern "C"boundary). #106109 (Raúl Marín). - Fix incorrect results for queries against tables whose
ORDER BYcontains a monotonically decreasing function such as(c0 / -42)orintDiv(c0, -42). Predicates on the underlying column (for example,c0 < 0) could wrongly prune granules that contained matching rows, producing missing results. Closes #106084. Closes #106124. Closes #106080. #106136 (Nihal Z. Miaji). - Fix support for using
WASMSQL UDFs inMATERIALIZED VIEWdefinitions. #106161 (Yue Ni). - Iceberg partition pruning now correctly handles
WHERE partition_col = (SELECT ... FROM ...)filters where the analyzer wraps the scalar subquery result in an internal_CAST(Const, 'TargetType')with matching source and target types. Previously such filters disabled partition pruning and triggered a full table scan. #106204 (Groene AI). - Fix clickhouse local's
--query_idparameter to allow it to specify custom query id. #106205 (Yue Ni). - Fixed the S3 storage class (
s3_storage_class/s3_storage_class_name) being ignored for objects written via multipart upload onS3disks and object storage, which caused large objects to be created with the defaultSTANDARDclass. The option name is now accepted both ass3_storage_classands3_storage_class_namefor disks, object storage and backups. #106214 (Alexey Milovidov). - Fixed Keeper sometimes getting stuck on startup when setting
nuraft_max_log_gap_in_streamis set to non-default value (default is 0, i.e. disable pipelining ofappend_entriesrequests). #106220 (Michael Kolupaev). - Validate corrupted
DDSketchaggregate-function state (bin keys) on insertion instead of accepting malformed data. #106236 (Yarik Briukhovetskyi). - Fixed coordinator mode mismatch when subqueries override in-order settings. #106243 (Nikita Taranov).
- Fix
optimize_skip_unused_shardsdid not apply (andforce_optimize_skip_unused_shardsfalsely failing) when aDistributedtable is queried through aMergetable or themergetable function, with the predicate applied above it. #106250 (Nikolai Kochetov). - Fix
INTERPOLATE ()throwingINVALID_WITH_FILL_EXPRESSIONwhenORDER BYcolumns are aliased in theSELECTlist with the old analyzer. Closes #106248. #106252 (Yakov Olkhovskiy). - Fixed an abort when deserialising a malformed
AggregateFunction(uniqTheta, ...)state fromRowBinaryinput or a query parameter. The bad input is now rejected withCORRUPTED_DATAinstead of escaping as astd::exceptionand aborting the process viaabortOnFailedAssertion. #106260 (Groene AI). - Reject out-of-range
IntervalKindbytes duringRowBinaryWithNamesAndTypestype decoding (input_format_binary_decode_types_in_binary_format = 1) with a clearINCORRECT_DATAerror instead of constructing aDataTypeIntervalwith an invalid kind that could subsequently trip undefined behavior in hash paths. #106261 (Groene AI). - Fix
SLRUdowngrade failure rollback issue in26.1+. FixSystem/Datacache split priority withkeep_free_space_ratiofeature. #106286 (Kseniia Sumarokova). - Read the
nullsubcolumn as aJSONpath inNullable(JSON)instead of the null-map. Closes #106085. #106295 (Pavel Kruglov). - Fix
RestCatalog::emptyreturning the wrong result when an Iceberg REST catalog contains tables. #106301 (Lefteris). - Fixed an exception for
INNER JOINqueries with an empty leftMergeTreetable whenenable_parallel_replicas,query_plan_use_new_logical_join_step, andquery_plan_optimize_join_order_algorithm = 'greedy'are enabled. #106338 (Nikolai Kochetov). - Fixed an incorrect conversion of subnormal
Float16values toFloat32(e.g. when reading them from Numpy.npyfiles), caused by an off-by-one mantissa shift. #106343 (Joanna Hulboj). - Fix a crash and a possible
NOT_FOUND_COLUMN_IN_BLOCKerror when constraint-based optimization (optimize_using_constraints) is used with correlated subqueries. #106349 (Raúl Marín). - Fixed an out-of-bounds read in
sipHash64Keyed,sipHash128KeyedandsipHash128ReferenceKeyedwhen hashing a column whose arrays are all empty and the key is not constant. #106355 (Raúl Marín). - Fixed
SYSTEM RELOAD CONFIGdiscarding per-endpoint Azure Blob Storage settings (such asuse_native_copy), which caused a disk's configured settings to be ignored forBACKUP/RESTOREuntil the server was restarted. #106357 (Julia Kartseva). - Fix
regexpExtract(haystack, pattern)so that patterns without a capturing group return the whole match instead of throwingINDEX_OF_POSITIONAL_ARGUMENT_IS_OUT_OF_RANGE. #106374 (Groene AI). - Fix
LOGICAL_ERRORexception during cache predownload when a remote S3 object is overwritten with shorter content between listing and reading. #106375 (Nikita Fomichev). - Fix memory usage growth in filesystem cache. #106387 (Kseniia Sumarokova).
- Fix multiple heap out-of-bounds reads in the Arrow IPC format reader (
ArrowColumnToCHColumn). A malformed Arrow file could declare more rows than its buffers contain, declare list/struct/map child lengths inconsistent with their parent, supply non-monotonic list offsets, or truncate a child validity bitmap, causing reads past the end of heap allocations. This is reachable by any user withSELECTprivilege viafile(),format(), table functions, or ArrowFlight inputs. All data, offsets, view-struct, and validity-bitmap buffers are now validated before any raw pointer access, and list/struct/map shapes and offsets are checked for consistency. #106395 (Raúl Marín). - Fixed backups failing with
FILE_DOESNT_EXISTwhen a refreshable materialized view's REPLACE target is collected on a Replicated or Shared database whose materialized view isn't yet instantiated on the backup-initiating replica. #106411 (Julia Kartseva). - Fix a logical error
Column identifier ... is already registeredwhen a mutation (DELETE/UPDATE) predicate contains anIN/EXISTSsubquery that reads from a default table expression nested in another subquery. #106414 (Alexey Milovidov). - Fix a logical error (
Left and right columns have same names) in the join order optimizer that could occur for joins executed with parallel replicas when two relations in the join graph share column names. #106418 (Alexey Milovidov). - Fix a logical error when building a polygon dictionary from source data containing
NaNor infinite point coordinates. Such coordinates are now rejected with a clear error. #106423 (Alexey Milovidov). - Fixed a bug where the
used_privilegesandmissing_privilegescolumns ofsystem.query_logcould contain privilege strings leaked from unrelated earlier queries of a different user, database, or session. #106425 (Alexey Milovidov). - Functions
base58Encode,base58DecodeandtryBase58Decodenow respectmax_execution_timeand query cancellation on large inputs, and reject inputs larger than 10 KB instead of running for a very long time. The limit is configurable via the new settingfunction_base58_max_input_size(0disables it). #106428 (Alexey Milovidov). - Fix sporadic incorrect results for
ORDER BY ... DESCqueries when reading wide parts in reverse order withread_in_order_use_virtual_row_per_block = 1and a smallmax_block_size. #106429 (Vladimir Cherkasov). - Fixed a
NOT_FOUND_COLUMN_IN_BLOCKexception when querying an Iceberg or S3 table with a compoundWHEREcontainingIS NOT NULLon a column that is not in theSELECTlist, using the Parquet V3 native reader. #106443 (Shaohua Wang). - Allows user to specify headers for
HTTPDictionaryusing named collections. #106459 (Jan Rada). - Fix a case where a worker thread could stay attached to a stale thread group after
CurrentThread::attachToGroupfailed part way through, causing later tasks on the same thread to fail withThread is already attached to a group. #106462 (Mikhail f. Shiryaev). - Fixed an exception when a vector search query uses a vector index and uses another skip index like
minmaxanduse_skip_indexes_on_data_read = 1. #106473 (Shankar Iyer). - Malformed
Avroenum values are now validated and rejected with an error instead of causing an out-of-bounds read and abort when deserializing corruptedAvrodata. #106476 (Miсhael Stetsyuk). - Fix inflated progress reporting when reading from Iceberg tables with
_fileor_pathfilters. Previously,total_bytes_to_readprogress included all files from the manifest regardless of filtering. #106491 (Pedro Ferreira). - Fixed a
Bad cast exceptionfor Redis dictionaries that useSTORAGE_TYPE 'simple'with acache/directlayout and a single string (complex) key; such dictionaries now work, and composite keys oversimplestorage report a clear error. #106501 (Vladimir Cherkasov). - Fix wrong-results bug where
WHERE c0 = constreturned no rows for tables withORDER BY f(c0)whenf(const)evaluates to NaN, e.g.ORDER BY sqrt(c0)with a negative constant. The primary-key analysis incorrectly pruned every granule and poisoned the query condition cache for subsequent queries. #106507 (Groene AI). - Fix
LIMIT WITH TIESand fractionalLIMIT WITH TIESnot respecting the collation fromORDER BY ... COLLATEwhen determining ties. Rows that are equal according to the collation (for example'1'and'01'under numeric collation) were compared byte-wise, so some tied rows were wrongly dropped from the result. #106539 (Nihal Z. Miaji). - Fix
DISTINCTin order andLIMIT BYin order optimizations (including negativeLIMIT BY) returning wrong results when the input is sorted with a collation (ORDER BY ... COLLATE). Rows that are equal according to the collation (for example'a'and'A'under a case-insensitive collation) are ordered by collation key and are not adjacent by value, so the in order optimization is now skipped when a collator is used. #106564 (Nihal Z. Miaji). - Fixed wrong results for
SELECT c, count() FROM t WHERE c GROUP BY cagainst tables with the implicit_minmax_count_projection, an explicit aggregate projection, or a normal projection: every group used to collapse into one row with a constant key and the total row count. #106590 (Groene AI). - Fixes a bug where users could not use scalar subqueries in the first argument of
INwhere the second argument is a non-constant tuple. #106610 (Yarik Briukhovetskyi). - Fix exception
Mutation ofMemorytable produced incomplete outputraised when runningALTER TABLE <memory_table>commands that have no per-row data effect on aMemoryengine, namelyAPPLY PATCHES,APPLY DELETED MASK,MATERIALIZE STATISTICS,MATERIALIZE INDEX,MATERIALIZE PROJECTION, andREWRITE PARTS.Memorytables do not own those structures, so such commands are now treated as no-ops. #106621 (Groene AI). - Fix
session_timezonebeing ignored when serializingLowCardinality(DateTime)columns to text formats (CSV, TSV, JSONEachRow, etc.). Previously, after the first write of aLowCardinality(DateTime)column on a server, every subsequent query that wrote such a column rendered the wall-clock string in whichever timezone was first seen, regardless ofsession_timezone. #106634 (Groene AI). - Fixed a
LOGICAL_ERROR"Trying to get name of not a column:ExpressionList" raised by queries that pass an asterisk insidemultiIfto a table function argument, e.g.numbers(multiIf(*, ...), 2). The query now rejects the unresolvable matcher withUNSUPPORTED_METHOD. #106647 (Groene AI). - Fix server failing to start with
Too many marks in file ...skp_idx_idx.cmrk4, marks expected 0 (bytes size 0)when aMergeTreetable has a skip-index part with zero granules and a non-empty marks file on disk. #106675 (Groene AI). - Reject pathological
fileglob patterns that would cause unbounded recursion in directory listing. A maximum recursion depth of 1000 is now enforced; queries that exceed it raiseTOO_DEEP_RECURSIONinstead of crashing the server with a stack overflow. #106676 (Groene AI). - Fix server abort
Bad cast from type DB::ColumnNothing to DB::ColumnVector<char8_t>inFunctionIf::executeForConstAndNullableConditionwhen theif/multiIfcondition constant-folds toConst(Nullable(Nothing))(for example, an out-of-range subscript on an empty array, likearraySort(x -> x, [])[toNullable(1)]). #106678 (Groene AI). - Fix exception
'Trying to read from input() twice.'raised when the table functioninputis wrapped in a non-MATERIALIZED CTE that is referenced from more than one place in the query. The query is now rejected with a cleanINVALID_USAGE_OF_INPUTerror at planning time.inputis a one-shot client stream and can only be consumed by a single source in the query plan. #106682 (Groene AI). - Make
FORMATapply to theEXPLAINoutput ofEXPLAIN ... INSERT ... SELECT ... FORMAT ...also whenSETTINGSprecede theFORMATor the output format isValues. Follow-up to #101772. #106686 (Alexey Milovidov). - Fixed a rare spurious
RESOURCE_ACCESS_DENIEDerror ("Scheduler queue with resource request is about to be destructed") for a query that was actually granted access to a workload resource, caused by a reused thread-local request object retaining a previous request's failure. #106690 (Alexey Milovidov). - Fix a race between destroying
INATSConsumerobjects and callingINATSConsumer::onMsgon them via callbacks in the NATS library. #106692 (Miсhael Stetsyuk). - Fixed
match,extract,extractAllandcountMatchesreturning wrong results for regular expressions containing hex or octal escapes. #106709 (ofeliacode). - Keeper's internal Raft TLS now honors the
openSSL.client.verificationModesetting. Previously peer certificate verification was always enabled for inter-Keeper Raft communication regardless of this setting, sononewas silently ignored. Nownoneexplicitly disables Raft peer-certificate verification, while an absent setting keeps the previous secure-by-default behavior. Configurations that explicitly setnonewill stop verifying Raft peer certificates after upgrade, matching the configured intent. #106726 (Antonio Andelic). - Fix logical error in startup scripts in
SYSTEM RELOAD CONFIG. Additionally, load startup scripts onSYSTEM RELOAD CONFIG(currently private-only functionality). #106727 (Miсhael Stetsyuk). - Revert a change that made
sumMap/ the-Mapcombinator reject custom-named numeric value types (such asSimpleAggregateFunction(sum, T)andBool) withILLEGAL_TYPE_OF_ARGUMENT: Values for -Map cannot be summed, breaking previously-working aggregations. #106729 (Nikita Fomichev). - Fixed multiple memory-safety and resource-exhaustion issues in format readers reachable from untrusted input: a heap out-of-bounds read in the native Parquet reader's
DataPageV2definition/repetition level-length handling, a stack overflow on Parquet files with deeply nested schemas, and allocations that ignoredmax_memory_usagewhen parsing GeoParquet WKB/WKT geometry and Avro strings/bytes. #106739 (Raúl Marín). - Fixed a heap buffer overflow (server crash) in
decodeHTMLComponentwhen decoding strings containing the expanding HTML entities≫⃒or≪⃒, reachable by any user with a singleSELECT. #106741 (Raúl Marín). - Reject
CREATE TABLE,ALTER TABLE ADD INDEX, andCREATE INDEXwithGRANULARITY 0for skipping indexes with a clearBAD_ARGUMENTSerror. Previously this triggered anInconsistent AST formattingexception in debug builds. #106783 (Groene AI). - Fixed Azure BACKUP/RESTORE ignoring endpoint settings for legacy-form
azure_blob_storagedisks. #106784 (Julia Kartseva). - Fixed a
Bad castexception while pruning parts byMinMaxstatistics when a key column isLowCardinalityand the predicate constant isLowCardinality(Nullable(...)). #106793 (Groene AI). - Fix inconsistent columns (that leads to
LOGICAL_ERRORlater) on exception (i.e.MEMORY_LIMIT_EXCEEDED) during parsing. #106802 (Azat Khuzhin). - Fix after configuring
keeper_server.http_control.secure_port, the server returned an HTTP response when making requests to HTTPS clients. #106822 (linjiayu1025-collab). - Fix logical error in
parseDateTimewith non-ASCII input bytes. #106856 (Pavel Kruglov). - Fix
SHOW CREATE ROW POLICYemittingrestrictive/permissivein lowercase instead of uppercase, inconsistent with other keywords. #106865 (Valery Petrov). - Fixes the case when parallel replicas wasn't applied for view with
UNIONdue to empty table in theUNION. #106900 (Igor Nikonov). - Fix server crash (SIGSEGV) when reading truncated
Protobufdata withinput_format_allow_errors_num > 0. #106905 (Andrey Tsarevskiy | Андрей Царевский ). - Fix
THERE_IS_NO_COLUMNexception for distributed queries involvingoptimize_rewrite_aggregate_function_with_ifoptimization when the aggregate function argument requires a cast toNullabletype. #106908 (Yakov Olkhovskiy). - Fix an exception (
LOGICAL_ERROR) in the join runtime filter when the join key contains aVariantorDynamictype nested inside aTuple,Array, orMapand the right side of the join has a single distinct value. #106931 (Groene AI). - Fixed a signed integer overflow (undefined behavior) in
arrayLevenshteinDistanceWeightedandarraySimilaritywhen the weight arrays contain large integer values. The weighted distance is now accumulated in a wide integer for integral weights, so large integer weights no longer overflow and stay exact. #106934 (Groene AI). - Fix a server crash (null pointer dereference) when running
TRUNCATEorDROPon anEmbeddedRocksDBtable whose RocksDB handle was released, for example aread_onlytable whose data directory was emptied by a priorTRUNCATE. #106940 (Groene AI). - Fix an exception (
std::length_errorreported as aLOGICAL_ERROR) when reading from a*Clustertable function such asurlClusterwith a very largemax_streams_for_files_processing_in_cluster_functionssetting. The number of streams is now bounded to a sane value. #106946 (Groene AI). - Fix a server crash (null pointer dereference of
DB::IConnections) inRemoteQueryExecutorwhen a distributed query is cancelled right before it is sent to a shard. #106950 (Groene AI). - Fixed
elapsed_usalways being zero, andread_rows/read_bytesbeing undercounted, insystem.processors_profile_logandsystem.query_logfor asynchronous insert flush (AsyncInsertFlush) queries. #106982 (Christoph Wurm). - Fix a crash (
Source column is not Map/SIGSEGV) when merging sorted blocks that contain aVariantcolumn with aMapvariant whose local storage order differs from its global order. #107011 (Groene AI). - Fix a logical error
conflicted_part_name.has_value()raised during a synchronous insert into aReplicatedMergeTreetable when the inserted block was fully deduplicated and the conflicting part's deduplication node had already been removed (for example by a concurrentDROP PARTITION). #107026 (Groene AI). - Fixed an exception (logical error
this->visited_views == right->visited_views) onINSERTwhen two materialized views on the same source table write to the same target table and a dependent view reads that target, withmaterialized_views_squash_parallel_insertsenabled. #107027 (Groene AI). - Fixed a
Block structure mismatch in UnionStep streamlogical error (server abort on debug/sanitizer builds,Code: 49on release builds) that occurred when one branch of aUNION/INTERSECT/EXCEPTread aSparse-serialized column while the sibling branch read the same column as a full one (for example when pushing to a materialized view). #107041 (Groene AI). - Fixed a
LOGICAL_ERRORexception when inserting into a DeltaLake table with columns that do not match its write schema (for example aNestedcolumn that flattens to subcolumns, or a table function with an explicit column subset). Such inserts now fail with a user-facingINCOMPATIBLE_COLUMNSerror instead. Closes #87402. #107058 (Groene AI). - Fix
TYPE_MISMATCHerror ("Cannot convert string ... to type ...") forORDER BY <numeric column> ... LIMIT nqueries when lazy materialization placed another column before the sort column. The top-K threshold is now read from the correct sort column. #107060 (Groene AI). - Fixed a syntax error when a
FORMAT,SETTINGS, orINTO OUTFILEclause followsSHOW ROW POLICIESorSHOW MASKING POLICIES(e.g.SHOW ROW POLICIES FORMAT TabSeparated). #107061 (Groene AI). - Fix a compound
ALTER TABLE ... RENAME COLUMN a TO b, RENAME COLUMN c TO athat reuses a freed column name (a "swap") between columns of different types. The materialized part recorded the wrong column type, so a laterSELECTfailed withConversion between numeric types and IPv6 is not supported(or aborted on part load in debug builds). #107064 (Groene AI). - Fixed non-deterministic results of the
roundDownfunction when the boundaries array containsNaN. The same input value could return a finite boundary orNaNdepending on the surrounding rows in a batch.NaNboundaries are now ignored, so the result depends only on the finite boundaries. #107065 (Groene AI). - Fixed
quantileTDigestandquantileTDigestWeightedthrowingDECIMAL_OVERFLOWforDateandDateTimearguments when the interpolated quantile is fractional but in range (for examplequantileTDigestWeighted(date, weight)on values that all fit in the type). The fractional result is now truncated to the result type, matchingquantilesTDigestWeighted; genuine out-of-range values still raise an error. Closes: #106722. #107066 (Groene AI). - Fix
trimLeft,trimRight, andtrimBoth(and aliasesltrim,rtrim,trim) throwingTOO_LARGE_STRING_SIZEwhen the custom trim character set is longer than 16 characters. Trim sets of any length are now supported again. #107071 (Nikita Fomichev). - Fixed silent truncation of out-of-range integer values in
Enum8/Enum16type definitions.Enum8('a' = 200)now throwsARGUMENT_OUT_OF_BOUNDinstead of silently creatingEnum8('a' = -56). #107081 (Groene AI). - Fix wrong row order (and a
LOGICAL_ERROR"Rows are not sorted with permutation" in debug builds) for multi-columnORDER BY ... LIMITqueries that sort byNullablecolumns when several rows tie on the leading columns. #107094 (Groene AI). - Fix a
LOGICAL_ERROR(Expected the argument N to have X rows, but it has Y) when executing a function over aDynamiccolumn built by a JOIN overDynamic(for example the non-joined rows of aRIGHT/FULL JOIN, or a correlatedEXISTSsubquery decorrelated into a join). #107095 (Groene AI). - Fix spurious ZooKeeper session recreation on config reload. #107096 (Azat Khuzhin).
- Do not hold mutex across ZooKeeper reads in access entities refresh. #107097 (Azat Khuzhin).
- Fix a
Logical error: Too large size passed to allocatorexception onINSERTinto aMergeTreetable whenadaptive_write_buffer_initial_sizeis set to an extremely large value. The adaptive write buffer initial size is now clamped to the buffer maximum. #107104 (Groene AI). - Fix
LOGICAL ERROR(Bad cast from type DB::ColumnString to DB::ColumnLowCardinality) when aVariantconstant containing aLowCardinalitymember is compared to a key column whose key expression is a non-monotonic deterministic function (for example aminmaxskip index oversipHash64(col)). #107111 (Groene AI). - Fix a
Bad cast from type DB::IColumn const* to DB::ColumnNullable const*logical error when a qualified asterisk (t.*) over aJOIN ... USINGkey is passed to an aggregate function and the other side of an outer JOIN has aNullablekey (withjoin_use_nulls = 0). #107129 (Groene AI). - Fix
ALTER TABLE ... ON CLUSTERbatches that mixMODIFY SETTING/RESET SETTINGwith a comment change (for exampleMODIFY COMMENT 'x', MODIFY SETTING old_parts_lifetime = 123) being applied only on the leader replica, leaving the other replicas diverged. Also fix a positional or per-column-SETTINGSMODIFY COLUMN ... COMMENTbeing misclassified as a local comment-only metadata change, which left the column reorder out of the replicated metadata and could causeINCOMPATIBLE_COLUMNSon replica restart. #107142 (Groene AI). - Fix a
LOGICAL_ERROR("Table expression ... data must be initialized") raised when a qualified asterisk matcher (for examplex.*) referenced a recursive CTE by name inside its own recursive term. Such matchers now expand the recursive table's columns, the same way a qualified column (x.a) or an unqualified matcher (*) already does in that position. #107144 (Groene AI). - Fixed wrong query results caused by the query condition cache when on-fly mutations (
apply_mutations_on_fly) or patch parts filtered rows beforePREWHERE. A query reading withapply_mutations_on_fly = 1could poison the cache so that a later query withapply_mutations_on_fly = 0and the same predicate skipped marks it should have read and returned too few rows. The same fix also covers row-level security policies, which are prepended as a filter ahead ofPREWHERE: a query run under a restrictive row policy could poison the cache for a later query that uses the same predicate without that policy. #107145 (Groene AI). - Fixed
BACKUPtoAzureBlobStorage: copying a data file inside a backup wrote the destination object outside the backup directory. Backup object existence checks onS3destinations now use exactHeadObjectrequests instead of prefix listing, preventing false matches of similarly-prefixed keys. #107153 (Pablo Marcos). - Fixed a signed integer overflow in
quantileExactExclusive,quantilesExactExclusive,quantileExactInclusiveandquantilesExactInclusivethat could produce a wrong result forInt64inputs spanning a large range. #107154 (Groene AI). - Fixed a
LOGICAL_ERROR("Unexpected exception in refresh scheduling") that could put the server into a crash-loop on restart when a refreshable materialized view has aREFRESH ... DEPENDS ON <name>dependency whose unqualified name matches a temporary table or a CTE name. #107156 (Groene AI). - Make sure we don't run startup scripts on config reload, as that is semantically wrong and unexpected by users - and has been known to be error-prone. #107187 (Miсhael Stetsyuk).
- Cap the max value for
queue_sizefor pre-reserve. #107205 (Elian Gidoni). - Fix the
Argument ... of GROUPING function is not a part of GROUP BY clauseerror for queries that use thegroupingfunction with thegroup_by_use_nullssetting enabled. #107206 (Nikolai Kochetov). - Fix incorrect result order for
ORDER BYoverUNION ALLwithoptimize_read_in_orderenabled when the union pipeline was narrowed due tomax_streams_for_union_stepsettings; narrowing is now skipped when the plan relies on sorted UNION output streams. Closes #106880. #107208 (Vladimir Cherkasov). - Fixed a possible null pointer dereference while resolving proxy configuration during late server shutdown. #107231 (Pedro Ferreira).
- Fix lightweight
UPDATEqueries with legacy parallel replicas enabled for non-replicatedMergeTreetables. #107246 (Groene AI). - Fixed a server abort (
std::out_of_rangelogical error) when inserting into anIcebergtable whose write block column names do not match the field ids of the latest schema (for example after a concurrent writer renames a column within theiceberg_metadata_staleness_mswindow). The insert now fails with a clean query error instead of crashing the server. #107279 (Groene AI). - Fix the stuck shutdown bug on server and local due to static thread pools keeping idle threads indefinitely if
max_*_thread_pool_free_size > 0. #107291 (Miсhael Stetsyuk). - Fix the
s3table function silently ignoring a lowercase positionalpartition_strategy(e.g.hive). #107297 (Julia Kartseva). - Fix
low_cardinality_allow_in_native_format=0handling in parallel blocks marshalling. #107319 (Azat Khuzhin). - Fix wrong (often empty) results from
ORDER BY <col> LIMIT nwhen theuse_skip_indexes_for_top_koptimization is active and a part with aminmaxskip index on the sort column has had rows removed by a lightweightDELETE. The optimization no longer ranks the stale minmax of lightweight-deleted parts ahead of the parts that hold the live top rows. #107320 (Groene AI). - Fixed a bug in ClickHouse Keeper where the snapshot metadata reported via
last_snapshot(andzk_latest_snapshot_sizeinmntr) could move backwards after a stale or duplicated snapshot install, which could also let a same-index local snapshot overwrite a registered snapshot file in place while it was still being streamed to a peer or uploaded to S3. #107321 (Antonio Andelic). - Fixed possible server stack overflow (crash) when reading a deeply nested schema or value in the
MsgPack,BSON,ORC,Parquet,JSON,DeltaLake,IcebergandPaimonformats. Such deeply nested input is now rejected with an exception. #107341 (Raúl Marín). - Fix a possible logical error in
SYSTEM SYNC DATABASE REPLICA ... STRICTand make theSTRICTmodifier actually take effect for database replicas. #107344 (Pedro Ferreira). - Fixes a server abort in debug/sanitizer builds when reading a
DeltaLaketable whose ClickHouse schema names a column that is absent from the Delta column mapping, for example after a column was renamed or dropped in the Delta log. The query now fails with a catchableINCORRECT_DATAerror instead. #107347 (Groene AI). - Fix
ORDER BY ... WITH FILLproducing extra rows when anORDER BYcolumn before the fill column uses aCOLLATEcollation. The rows are now grouped by the sorting prefix using that collation, matching the sort order. #107365 (Groene AI). - Fixed a crash (
LOGICAL_ERRORin debug builds) and a silent wrong-results bug (in release builds) when reading an Iceberg table whose metadata re-binds an existingschema-idto a different schema across metadata versions. Such metadata is now rejected withICEBERG_SPECIFICATION_VIOLATION. #107370 (Groene AI). - Fix a
LOGICAL_ERROR(Variant N (T) has size X, but expected Y) when a function such astoStringorconcatis applied to aVariantorDynamiccolumn that holds a single non-empty variant together with NULLs, and the function returns its input column unchanged. #107374 (Groene AI). - Fix
Logical error: 'Duplicate announcement received for replica number N'that could occur with parallel replicas when a scalar subquery contained nested subqueries reading the same table. #107381 (Groene AI). - Fix
getServerSettingto return the live effective value for runtime-changeable server settings (such asmax_server_memory_usage,mark_cache_size,max_concurrent_queries, thread pool sizes, etc.), matching whatsystem.server_settingsreports. #107388 (Alexey Milovidov). - Fix
arrayResizewith aDecimalsize argument: the size is now interpreted by its real value (e.g.arrayResize([1, 2, 3], 1.5::Decimal(2, 1))returns one element) instead of the raw unscaled representation. #107389 (Alexey Milovidov). - Fix a
LOGICAL_ERROR(block.rows() == getRows()) raised on an asyncINSERTinto anAliastable whenuse_strict_insert_block_limitswas enabled. #107400 (Groene AI). - Fix a logical error (
Unexpected return type from equals. Expected Nullable(UInt8). Got UInt8) when the disjunction (partial predicate) push-down optimization pushes a condition over aUSINGkey whose type is widened by the JOIN. Also fix a server crash (segmentation fault) in the analyzer when resolving identifiers inJOIN ... USINGqueries that contain constant-foldableif/multiIfbranches referencing unknown identifiers. #107407 (Groene AI). - Fixed a heap buffer overflow (server crash) in
windowFunnelwhen finalizing a crafted aggregate-function state with an out-of-range event type, reachable by any user with a singleSELECT. #107412 (uwezkhan). - Fixed undefined behavior when a non-finite floating-point value (such as
nanorinf) is passed as the timestamp/duration argument of theprometheusQuery/prometheusQueryRangetable functions. Such an argument now raisesBAD_ARGUMENTSinstead of producing a garbage timestamp. #107417 (Groene AI). - Fix
MaterializedPostgreSQLsilently stopping replication of changes when the PostgreSQL database or table name contains upper-case letters (thepgoutputconsumer requested an unquoted, lower-cased publication name that did not match the case-preserving publication). #107423 (Alexey Milovidov). - Fix an exception (
Logical error: Not-ready Set is passed as the second argument for function 'in') when a key expression (ORDER BY,PRIMARY KEY,PARTITION BY, or a skipINDEX) contained anINoperator with a table on the right-hand side, e.g.ORDER BY (x IN some_table). Such key expressions are now rejected at table creation time. #107424 (Groene AI). - Fix incorrect results from the
optimize_rewrite_aggregate_function_with_ifoptimization for aggregate functions that preserveNULLpayload values (the*_respect_nullsfamily:anyRespectNulls,first_value_respect_nulls,anyLast_respect_nulls,last_value_respect_nulls). The optimization no longer rewritesf(if(cond, x, NULL))into the-Ifform for such functions. #107430 (Groene AI). - Fix a spurious
filesystem error: in last_write_time: No such file or directoryexception when listing a local-disk object storage directory (e.g. an Iceberg table on alocaldisk) while files are being concurrently replaced. A concurrently removed entry is now omitted from the listing instead of aborting it. #107432 (Groene AI). - Fix
THERE_IS_NO_COLUMNerror whenoptimize_if_transform_strings_to_enum = 1and the optimizedif/transform-over-string-literals expression is aGROUP BYorORDER BYkey over a Distributed table or parallel replicas. #107455 (Groene AI). - Fixed a rare server crash in
DISTINCTprocessing that could occur when an allocation failed (for example, when hitting a memory limit) while the set of distinct keys was being initialized. #107467 (Groene AI). - Fix
LOGICAL_ERROR: Unexpected return type from materialize(and similar type-mismatch errors) whenapply_mutations_on_fly = 1is used on a table with a pending on-flyUPDATEwhose target column is also read as a function input by an earlier on-flyUPDATE, before anALTER MODIFY COLUMN ... LowCardinality(...)mutation. #107475 (Groene AI). - Fixed stale AWS STS credentials when reading
DeltaLaketables overS3: the engine now keeps the freshly-credentialedS3client when refreshing its snapshot, so long-running reads no longer fail after the STS token's TTL expires. The STS assume-role credentials provider now also honors credential refresh for anyS3access using STS. #107480 (Elmi Ahmadov). - Fixed
SELECT ... FINALandOPTIMIZE TABLE ... FINALreturning duplicate rows afterCREATE TABLE ... CLONE AS,ATTACH PARTITION ... FROMorMOVE PARTITION ... TO TABLEadopted parts from a plainMergeTreeinto aReplacingMergeTree,SummingMergeTreeorAggregatingMergeTree. The adopted part's merge level is now reset to 0 when the source and destination engines differ, so the destination deduplicates it on the next merge. #107481 (Groene AI). - Fix an integer underflow in the PostgreSQL wire protocol parser where a message with a length field smaller than 4 caused a
size - 4wraparound and an oversizedresize/ignore. #107485 (uwezkhan). - Query cancellation is now better tracked while waiting for the quorum in ReplicatedMergeTree. #107513 (Nikita Taranov).
- Fixed a
Not-ready Set is passed as the second argument for function 'in'(LOGICAL_ERROR) when querying a table with aPARTITION BYkey and anIN/NOT INsubquery wrapped inside a larger expression, for exampleWHERE (c0 IN (SELECT ...)) != 0. #107515 (Groene AI). - Fixed
currentUser(),user(),SESSION_USERandauthenticatedUser()evaluating to an empty string on the asynchronous insert flush path (withasync_insert = 1). This affectedDEFAULT/MATERIALIZEDcolumn expressions and materialized views that reference these functions, which silently stored an empty string instead of the inserting user. #107541 (Groene AI). - With
enable_analyzer = 1(the default), querying a table by its bare name when it only exists in another database now suggests the right table, e.g.SELECT * FROM functionsreportsMaybe you meant system.functions?. Previously the new analyzer gave a hint-lessUnknown table expression identifiererror, while the old analyzer already produced the helpful suggestion. #107550 (Groene AI). - Account memory used by the rapidjson library (in
prettyPrintJSON,JSONMergePatchand the rapidjson JSON parser) against the memory tracker, so pathological inputs are rejected withMEMORY_LIMIT_EXCEEDEDinstead of allocating without bound. #107555 (Raúl Marín). - Fix a
LOGICAL_ERROR(updateFormatPrewhereInfo called more than once) raised when querying afile(),url(), or object-storage source with both an explicitPREWHEREand aWHEREwhileoptimize_prewhere_after_pushdownwas enabled. #107568 (Groene AI). - Fix a crash (null pointer dereference) that could happen when a distributed query plan was executed locally (
make_distributed_plan+distributed_plan_execute_locally) withlog_formatted_queries = 1. #107570 (Groene AI). - Fixed a server abort (
std::terminate, signal 6) during teardown of a distributed-plan query (make_distributed_plan = 1) when a worker status-check failed to re-schedule the next check (for exampleCANNOT_SCHEDULE_TASKon shutdown orMEMORY_LIMIT_EXCEEDED). The query now fails cleanly and the server keeps running. #107575 (Groene AI). - Added missing bounds checks in Elf and DWARF parsing. #107579 (Michael Kolupaev).
- Added missing bounds checks in ORC reader. #107580 (Michael Kolupaev).
- Fixed an exception (
Digest does not matchlogical error) that could happen onRENAME TABLE,RENAME DATABASE, orCREATE OR REPLACE TABLEinvolving aTimeSeriestable inside aReplicateddatabase. Renaming aTimeSeriestable is now supported. #107583 (Groene AI). - Fix an unauthenticated memory-exhaustion denial of service on the MySQL protocol port. #107599 (Shaohua Wang).
- Fix
DROP TABLEof aTimeSeriestable in aReplicateddatabase, which previously leaked the inner tables and left the background drop task retrying forever (DROP TABLE ... SYNCwould hang). #107604 (Groene AI). - Fixed two path-traversal issues in the replicated part fetch protocol that could let a malicious replica write files outside the part directory. #107606 (Antonio Andelic).
- Fixed 'Account must be specified error' when reading a Delta Lake table over Azure. #107620 (Smita Kulkarni).
- Fixed
ALTER TABLE ... REPLACE PARTITIONon a plainMergeTreetable resurrecting the replaced-out parts after a server restart, which made the table return both the replacement rows and the stale replaced rows. #107623 (Groene AI). - Fix a server crash when reading a materialized view whose target is a
Distributedtable while the query runs withenable_analyzer = 0. #107653 (Groene AI). - When several quotas are assigned to the same user or role, all of them are now enforced together (a query is rejected if any of them is exceeded), instead of only one quota being enforced and chosen non-deterministically.
SHOW QUOTAandsystem.quota_usagenow show all quotas enforced for the current user. #107664 (Alexey Milovidov). - Fixed
s3and other object storage table functions throwingLOGICAL_ERRORinstead ofBAD_ARGUMENTSwhen a key-value argument is duplicated, e.g.s3('http://...', format = 'CSV', format = 'TSV'). #107670 (Groene AI). - Fixed the MySQL interface being unusable with
MySQL Connector/J8.2.0 and newer (including 9.x). Theinfofield of theOKpacket is now length-encoded, matching the MySQL server, so the JDBC driver can connect. #107693 (Alexey Milovidov). - Fixed a
LOGICAL_ERROR("Input nodes size mismatch in dag") when a query withmake_distributed_plan = 1joins on a function-wrapped key whose two sides have no common type (for exampleON intDiv(-1, t1.key) = t2.keywith aUInt64right key). #107701 (Groene AI). - Reading Arrow/ArrowStream data with empty
String/Binarycolumns produced by Apache Arrow Java < 19.0.0 (including Apache Spark) no longer throwsINCORRECT_DATA. #107764 (Raúl Marín). - Fixed a
BAD_GETexception ("Bad get: has String, requested UInt64") fromcountmincolumn statistics estimation when a query compares a column against a literal of a different type that is not pre-coerced, such asnumeric_col IN (SELECT '5')orstring_col IN (SELECT 5). #107793 (Groene AI). - Fixed the
odbcandjdbctable functions hanging for minutes and ignoring query cancellation (KILL QUERY,max_execution_time) when the bridge becomes unresponsive while inferring the remote table structure. #107809 (Alexey Milovidov). - Fixed an exception (
Logical error: 'index >= result.start') when formatting a malformed query that mixes the positional and named secret-argument forms of thes3/gcstable functions, e.g.s3('url', 'a', 'b', secret_access_key = 'c'). #107818 (Groene AI). - Fix set skip index not pruning granules over
LowCardinalitycolumns. #107868 (Konstantin Bogdanov). - Fixed insert deduplication computing wrong hashes for
StringandArraycolumns with the server settinginsert_deduplication_version = new_unified_hash: identical inserts could fail to deduplicate because the deduplication hash depended on the row's position within the inserted block. #107915 (Sema Checherinda). - Fix incorrect results of
ORDER BYoverNullablecolumns with multiple sort keys on macOS (Apple Silicon), caused by a missing sign-extension in the JIT-compiled sort comparator. #107973 (Raúl Marín). - Fix performance regression when reading
Dynamiccolumns with multiple threads. Caused by #100730. Closes #107942. #107997 (Pavel Kruglov). - The deprecated data lake setting
storage_catalog_urlis now correctly rejected by the catalog guard (previously onlystorage_catalog_typeandstorage_aws_access_key_idwere checked), and the error message lists all deprecated settings. #108040 (Alexey Milovidov). - Fix a
Bad cast from type DB::ColumnSparse to DB::ColumnVector<char8_t>logical error when aLIKEquery reads from atextindex via the direct-read fallback path over a column stored sparse. #108068 (Groene AI). - Always run access cache batch-finished handlers, even on empty batch. #108124 (Azat Khuzhin).
- Fixed a
LOGICAL_ERROR(Column identifier is already registered) for some queries withUNION ALL. #100770 (Shaohua Wang). - Fixed a use-after-free of the workload storage mutex during server shutdown. #101447 (Tuan Pham Anh).
- Fixed a deadlock in
ALTER DATABASE MODIFY COMMENTwith theSharedcatalog. #103683 (Nikolay Degterinsky). - An empty Unicode-quoted identifier now raises a
SYNTAX_ERRORinstead ofCANNOT_PARSE_QUOTED_STRING. #104173 (leonard9893). - Preserve the original parameter types of
timeSeries*aggregate functions so thatAggregateFunctiontypes round-trip correctly across table reattach and parallel replicas. #104812 (Vitaly Baranov). - Fixed a
LOGICAL_ERRORfor a materialized CTE underserialize_query_planwith parallel replicas. #104896 (Igor Nikonov). - Fixed signed integer overflow in the
timeSeries*ToGridfunctions when the staleness (window) parameter is nearINT64_MAX. #105319 (Groene AI). - A
compatibilitysetting value no longer revertsapply_row_policy_after_finaltofalse, so row policies are always applied correctly withFINAL. #105637 (Yarik Briukhovetskyi). - Fixed
clickhouse chdig clientby honoringSETPGROUP/RESETIDS/SETSIGDEFin theposix_spawnstub. #105858 (Azat Khuzhin). - Fixed an exception during merge-tree sanity checks on projections when the merge/mutate executor was not initialized. #105919 (Mikhail Artemenko).
- During index analysis on projections, the
minmaxindex is now loaded from the projection itself rather than from the parent part, producing correct results. #105940 (Mikhail Artemenko). - Fixed an exception in
addMonotonicChainformaterialize(monotonic_chain(...)). #106050 (Nikolai Kochetov). - Fixed
RESTOREfailing on backups that includeMASKING POLICYdependents. #106086 (Julia Kartseva). - Fixed possible memory corruption when expanding SQL user-defined functions with
prefer_column_name_to_aliasenabled. #106121 (Nikolai Kochetov). - A dictionary using the bridge connection is now reloaded after a server restart, re-establishing the connection. Closes #106151. #106152 (Pedro Ferreira).
- Fixed the filesystem cache for
LocalObjectStorage. #106239 (Kseniia Sumarokova). - Fixed the lazy remote source for table functions with
use_delayed_remote_source. #106470 (Nikolay Degterinsky). - Fixed
timeSeriesLastToGridfor timestamps before the grid start and out-of-window timestamps. #106504 (Vitaly Baranov). #106577 (Vitaly Baranov). - Fixed a
LOGICAL_ERROR(Inconsistent AST formatting) on a function name containing query parameters. #106635 (Vitaly Baranov). - Fixed a logical error when a table is dropped before distributed plan task deserialization. #106944 (Alexander Gololobov).
- Use exact comparison for
NullableGROUP BYkeys. #107050 (Nikolai Kochetov). - Fixed a
LOGICAL_ERROR(Trying to get name of not a column) raised when a table-function argument was not a column expression (for example an unresolved*matcher frommultiIf/CASE). #107411 (Alexey Milovidov). - Fixed unbounded growth of the time-zone cache (
DateLUT) when many distinct invalid time-zone names are processed. #107464 (Alexey Milovidov). - Write the
part_logentry before reporting a plainMergeTreemutation as done. #107741 (Azat Khuzhin). arrayFoldnow sanity-checks its array argument against malformed input. #107932 (Michael Kolupaev).- Fixed a rare data race and possible use-after-free on the cached skip-index archive reader of a
MergeTreepart, which could happen when a query read skip indices while the part was being moved or renamed. #107995 (Raúl Marín). - Fix performance regression for
Mapsubcolumns withPREWHERE. #107988 (Pavel Kruglov). - Fix
parseDateTimeBestEffortwith a timezone throwingCANNOT_PARSE_DATETIMEon NULL rows oftoString(Nullable(DateTime64)). #108310 (Yarik Briukhovetskyi). - Fixed the
ArrowFlighttable function and engine rejecting a named collection that omits the optionaldatasetkey with aNo such key 'dataset'error. #108041 (Alexey Milovidov). - Fixed an
Inconsistent AST formattinglogical error for a no-argument window function inside aCODECor engine declaration (e.g.CODEC(cume_dist() OVER (...))); such a function now keeps its parentheses so the query survives a format/parse round-trip. #107806 (Alexey Milovidov). - Fix
hasTokenwith a separator-containing needle silently returning results via a text index instead of raisingBAD_ARGUMENTS. #108189 (Jimmy Aguilar Mena). - The setting
use_skip_indexes_on_data_readcan now be reverted to its pre-26.1 default (false) via thecompatibilitysetting, providing an escape hatch for a performance regression where the on-data-read path defeatsminmax/set/bloom_filterskip-index mark-range pruning. #108330 (egor romanov). - Fixed a possible crash (null pointer dereference) when the
database/dboverride of a named collection passed toremote/remoteSecureis not a constant database name, e.g.remote(nc, database = (SELECT 1)). The query now fails with a clear error instead of crashing. #108271 (Groene AI). - Fixed refreshable materialized view getting stuck if the ZooKeeper connection is lost at the wrong moment. #108234 (Michael Kolupaev).
- Fix
Bad cast from type DB::ColumnVector<...> to DB::ColumnTuplewhen reading anArray(Tuple(...))column whose value is filled with defaults, e.g. afterALTER TABLE ... ADD COLUMNor after an unfinishedALTER TABLE ... CLEAR COLUMNmutation applied on the fly. #107232 (Groene AI). - Fix a
Bad cast from type DB::ColumnDynamic to DB::ColumnNullablelogical error when an explicit reference to aJOIN ... USINGkey whose common supertype isDynamicis passed to an aggregate function, for examplecount(t.key) IGNORE NULLS. #107289 (Groene AI). - Fix silent data loss on plain (non-replicated)
MergeTreewhenREPLACE PARTITION,MOVE PARTITION,DETACH PARTITION, orDETACH PARTis run on a partition that still has unapplied lightweightUPDATEpatches. These operations now reject the command, asReplicatedMergeTreealready does. #107386 (Groene AI). - Fix a crash (SIGSEGV in release builds, type-mismatch assertion in debug builds) in
hasover aMapwith aDynamickey when the lookup argument isLowCardinality, e.g.has(map('a'::Dynamic, ...), toLowCardinality('b')). #107956 (Groene AI). - Fixed a
LOGICAL_ERROR("Block structure mismatch ... betweenConvertingTransformandRemovingReplicatedColumnsTransform") when inserting into a materialized view whoseTOtarget table declares a column with a widerEnumthan the view'sSELECTproduces. The validEnumwidening is now applied. #107648 (Groene AI). - Fix
NUMBER_OF_COLUMNS_DOESNT_MATCHerror when querying aDistributedtable (or using parallel replicas) that has severalALIAScolumns expanding to the same expression and referencing them together withORDER BY/GROUP BY/HAVING. #107913 (Yakov Olkhovskiy). - Fixed undefined behavior (null pointer passed to
memcpy) in thedetectCharsetanddetectLanguageUnknownfunctions when the input string is larger than 32768 bytes and no character set can be detected. #108250 (Groene AI). - Fix
signed integer overflow(undefined behavior) indateDiffwithhourandminuteunits on extremeDateTime64values close to theInt64range limits. #108229 (Groene AI). - Fix
Too many marksfor a text index on an empty merged part. #106867 (Azat Khuzhin). - Fix a
LOGICAL_ERROR("Unexpected return type from if") when reading a column underapply_mutations_on_fly = 1after anALTER UPDATE col = ... WHERE <cond>with a non-constant or false condition followed byALTER MODIFY COLUMN col <new type>. #108128 (Groene AI). - Fix a server abort (
Logical errorinIColumn::insertFrom) when casting anArray(Dynamic)orArray(Variant)toQBitwithaccurateCastOrNull, e.g.accurateCastOrNull(CAST(range(114), 'Array(Dynamic)'), 'QBit(Float32, 114)'). #108288 (Groene AI). - Fixed a syntax error when an alias follows a subquery in
DESCRIBE TABLE (...) AS .... #100205 (Yarik Briukhovetskyi). getClientHTTPHeaderis now correctly treated as non-deterministic, so its result is no longer incorrectly reused by the query result cache. #108029 (Alexey Milovidov).
Build/Testing/Packaging Improvement
- Build
delta-kernel-rswith thedefault-engine-native-tlsfeature so that its own HTTP client (reqwest) can reuse the OpenSSL that ClickHouse already links in. This is only a partialnative-tlsenablement:object_storestill forcesreqwest/rustls-tls-native-roots, soreqwestends up with both thenative-tlsandrustlsbackends.delta-kernel-rsremains disabled under MSan for now becauseringis still compiled in viaobject_store(both transitively throughrustlsand directly for AWS request HMAC signing), and its hand-written assembly does not generate the symbols MSan requires (tracked upstream at arrow-rs-object-store#585). #96856 (Austin Bonander). - Add PGO (Profile-Guided Optimization) and BOLT (Binary Optimization and Layout Tool) post-link optimization for the
clickhousebinary. Profiles are collected from CI workloads and applied as a best-effort step during release builds — both stages fall back to non-optimized output if a profile is stale or incompatible. As of today, there are no benefits from PGO. #100938 (Alexey Milovidov). - Add
--storagemode toclickhouse keeper-benchthat benchmarksKeeperStoragein-process (no network, no raft, no state machine), using the samesetup/generatorconfig sections as the network mode. #103081 (Michael Kolupaev). - Fix build with
ENABLE_AWS_S3=OFF. #105390 (Yue Ni). - Update
mongo-cxx-driverto r4.3.0. #105522 (Konstantin Bogdanov). - Fix build against RapidJSON. #105674 (Ilya Golshtein).
- Speed up the build by removing transitive includes from widely-used base/ headers and stripping unused code from the vendored
Poco/Logger.h. #105702 (Raúl Marín). - Updated
libxml2from 2.15.1 to 2.15.3. #105985 (Konstantin Bogdanov). - Use
expat2.8.1 inside Poco. #105988 (Konstantin Bogdanov). - Bump
thrifttov0.23.0. #105993 (Konstantin Bogdanov). - Use
postgrestagREL_18_4. #105994 (Konstantin Bogdanov). - Upgrade
krb5to 1.22.2. #106076 (Konstantin Bogdanov). - Update bundled
curlto 8.20.0. #106077 (Konstantin Bogdanov). - Bumped
mariadb-connector-cto 3.1.29. All the ClickHouse-relevant patches preserved. #106287 (Nikita Mikhaylov). - Bump distroless base image digests for libssl3t64 CVE fixes. #106360 (Rahul Nair).
- Use
wasmtimev45.0.1. #106836 (Konstantin Bogdanov). - Bump
opensslto 3.5.7. #106844 (Konstantin Bogdanov). - Distroless Docker build now also updates the
:X.Y-distrolessand:X.Y.Z-distrolessfloating tags, not just the full-version tag. #106932 (Rahul Nair). - Disable unused
curlfeatures, such as NTLM auth, cookies, alt-svc, HSTS, DNS-over-HTTPS, netrc, MIME, AWS SigV4. #107226 (Konstantin Bogdanov). - Updated
NuRaftwith a fix for a snapshot-install livelock that occurred when snapshot IO ran on a background thread. Thenuraft_use_bg_thread_for_snapshot_ioKeeper setting remains disabled by default; CI now randomizes it to cover both modes. #107338 (Antonio Andelic). - Fix building
abseilwhen the ClickHouse checkout path contains a substring matching a header extension. #107349 (zhiqiang). - Determine the L2 cache size from
CPUIDon x86_64 instead of the glibc-specificsysconf(_SC_LEVEL2_CACHE_SIZE), which is not available under musl libc. #107469 (Konstantin Bogdanov). - Increase the stack size for musl builds to 8 MiB to support deeply-nested queries. #107470 (Konstantin Bogdanov).
- Derive the set of C library symbols localized in Rust static libraries from the actual reference libraries instead of a hand-maintained allowlist, so all compiler-rt builtins and platform libm functions are covered. #107571 (Raúl Marín).
- Switch the distroless server and keeper images to
gcr.io/distroless/base-nossl-debian13so they only ship the libraries ClickHouse actually links against and stop pulling in ones we statically link ourselves. #107837 (Rahul Nair). - Re-enable 50 stateless tests on macOS (
arm_darwin) that were stale-skipped, and usefsyncinstead ofF_FULLFSYNCfor directory syncing on macOS. #107887 (Raúl Marín).
ClickHouse release 26.5, 2026-05-21. Presentation, Video
Backward Incompatible Change
- Changed defaults of
date_time_input_formatandcast_string_to_date_time_modefrombasictobest_effort. Queries that previously failed to parse non-basic datetime strings (e.g.2024 April 4,Apr 15, 2020 10:30:00) may now succeed by default. To keep the old strict parsing behavior, set these settings tobasic(or usecompatibility). #89334 (Alexey Milovidov). - Tuple element name
nullis now forbidden because it conflicts with the subcolumn name used for Nullable null maps, causing ambiguous subcolumn resolution. #98377 (Alexey Milovidov). - Add a setting
dynamic_disk_allow_from_env,dynamic_disk_allow_from_zk,dynamic_disk_allow_includeto disallow usage offrom_env,from_zk,includein dynamic disks. Backward Incompatible Change because prohibits by default the behaviour which used to be allowed by default. #99138 (Kseniia Sumarokova). - You can no longer use the obsolete Arrow-based Parquet reader and writer. The native implementation will be used instead. #100949 (Alexey Milovidov).
SHOW CREATE TABLE tnow prefers the temporary table when both a permanent and a temporary table namedtexist and no database is specified, matching the existing behavior ofDESCRIBE TABLE. Additionally,DESCRIBE TEMPORARY TABLEsyntax is now supported. #100966 (Alexey Milovidov).- Reduced default
http_max_fieldsfrom 1,000,000 to 1,000 andhttp_max_field_name_sizefrom 128 KB to 4 KB to limit pre-authentication memory usage by HTTP connections. Addedhttp_max_request_header_sizeandhttp_headers_read_timeoutsettings. Users who rely on the previous higher limits can restore them via settings. #103285 (Sema Checherinda). - Added a
histogramsnested column tosystem.metric_logthat snapshots every registered histogram metric per row, with a newsystem_metric_log_show_zero_values_in_histogramssetting to control zero-value emission. Deprecates thesystem.histogram_metric_logtable. #103770 (Miсhael Stetsyuk). CASTtoDateTimeorDateTime64without an explicit time zone now preserves the time zone of its source argument (when the source is aDateTime/DateTime64with an explicit time zone), matching the behavior of thetoDateTime/toDateTime64functions. Closes #55072. #104433 (Alexey Milovidov).- Removed the
kqltable function. UseSET dialect = 'kusto'to run queries in the KQL dialect. #105101 (Alexey Milovidov). - The window functions
RANKandDENSE_RANKnow reject arguments and throwNUMBER_OF_ARGUMENTS_DOESNT_MATCH, in line with the SQL standard. Previously, queries such asRANK(x) OVER (ORDER BY id)were silently accepted with the argument ignored. To restore the previous lenient behavior, setallow_rank_dense_rank_arguments = 1. Closes #49526. #104324 (Groene AI).
New Feature
- Added a new setting
max_bytes_ratio_before_external_join, mirroringmax_bytes_ratio_before_external_group_byandmax_bytes_ratio_before_external_sort. It expresses the spill-to-disk threshold for hash joins as a fraction of available memory; combined with the absolutemax_bytes_before_external_join, the smaller resulting threshold applies. #103862 (Alexey Milovidov). Thenew max_bytes_ratio_before_external_joinsetting is now enabled by default at 0.5, mirroringmax_bytes_ratio_before_external_group_byandmax_bytes_ratio_before_external_sort. Hash joins automatically spill to grace hash join once the right-side data exceeds half of the available system memory (when memory limits are configured). #104285 (Alexey Milovidov). - Add table function
filesystem. It allows to represent directory structure as a table, to query files' metadata and contents with SQL. Originally #42039 by @perst20. See #42039. See #50208. #53610 (Alexey Milovidov). - Allow passing bare function names to higher-order functions like
arrayMap,arrayFilter, etc. For example,arrayMap(negate, [1, 2, 3])is now equivalent toarrayMap(x -> negate(x), [1, 2, 3]). #101033 (Alexey Milovidov). - Add setting
send_table_structure_on_insert_with_inline_dataand--inline-insert-dataclient option to allow the server to parse inline INSERT data itself over the native protocol, avoiding the round-trip to receive table structure and improving performance for many small inserts. #101034 (Alexey Milovidov). - Add
tokenizeQueryandhighlightQueryfunctions for SQL query tokenization and syntax highlighting.tokenizeQueryreturns lexer tokens with byte offsets and token types;highlightQueryreturns parser-based syntax highlighting ranges with highlight categories (keyword, identifier, function, number, string, etc.). #101054 (Alexey Milovidov). - Add
url_basesetting to resolve relative URLs in theurltable function andURLtable engine, following RFC 3986 semantics. #101113 (Alexey Milovidov). - Support negative values in the
LIMIT BYclause to select rows from the end of each group instead of the beginning. For example,LIMIT -2 BY idreturns the last two rows perid. Negative offsets (LIMIT -1 OFFSET -1 BY id) and mixed signs (LIMIT -2 OFFSET 1 BY id) are supported as well. #103222 (Nihal Z. Miaji). - Support
json_valuefunction to output withtupleandarrayto improve performance of multiple json query. #78362 (kevinyhzou). Support multi-pathTuple/ArrayJSONPath argument inJSON_VALUE,JSON_EXISTS, andJSON_QUERY, by @KevinyhZou. #101102 (Alexey Milovidov). - A new
kafka_autodetect_client_rackparameter is introduced. If set, discover the Availability Zone via cloud facilities and propagate it as theclient.rackparameter oflibrdkafkato avoid cross-zone communications. #81323 (Ilya Golshtein). - Add
Readevent type tosystem.blob_storage_logfor tracking object storage read operations, controlled by new settingenable_blob_storage_log_for_read_operations. #96867 (Alexey Milovidov). - Users can now see ZooKeeper watches issued by
clickhouse-serverusing the newsystem.zookeeper_watchestable. #99277 (Den Kalantaevskii). - Added
Shardsprofile event that counts the number of shards involved in distributed queries, summed across all tables. #99470 (Alexey Milovidov). WASMUDFs can be declaredDETERMINISTICand become a subject of constant folding. #100005 (Vasily Chekalkin).- Add
parallel_replicas_prefer_local_replicasetting: when disabled, parallel replicas are selected purely by the load balancing algorithm, allowing evenmax_parallel_replicas = 1queries to be directed to another host. #100139 (Alexey Milovidov). - Add
{disk,storage,http}_connections_rcvbufand{disk,storage,http}_connections_sndbufserver settings to control TCP socket buffer sizes on outgoing HTTP connections, allowing operators to override kernel autotuning and cap per-connection memory usage. #100478 (Sema Checherinda). - Support
CREATE OR REPLACE MATERIALIZED VIEWwith the same atomic swap semantics asCREATE OR REPLACE TABLE. Works with inner tables,TOtables,POPULATE,REFRESH, andON CLUSTER. #100539 (DQ). - Add
s3_read_request_duration_microsecondsands3_read_request_byteshistogram metrics to observe S3 GET request connection lifetime and bytes consumed, visible insystem.histogram_metricsand the Prometheus endpoint. #102058 (Sema Checherinda). - Add
Paimon,PaimonS3,PaimonAzure,PaimonHDFS, andPaimonLocaltable engines with incremental read support backed by Keeper snapshot progress tracking. Incremental mode returns only new rows since the last committed snapshot. Targeted snapshot delta reads are available viapaimon_target_snapshot_id, and per-query snapshot caps viamax_consume_snapshots. Background metadata refresh is configurable withpaimon_metadata_refresh_interval_sec. Gated byallow_experimental_paimon_storage_engine. #102343 (XiaoBinMu). - Added a new Kafka table setting
kafka_map_virtual_columns_on_write. When enabled, columns named_key,_timestamp,_headers.nameand_headers.valuein the Kafka table schema are produced as the corresponding Kafka message key, timestamp and headers onINSERT, and are excluded from the message payload. #103243 (Alexey Milovidov). - Added
SYSTEM PAUSE VIEW [db.]nameandSYSTEM PAUSE VIEWSqueries for refreshable materialized views. UnlikeSYSTEM STOP VIEW,SYSTEM PAUSE VIEWdoes not interrupt the currently running refresh — the in-flight refresh is allowed to complete and only subsequent refreshes are prevented. Undone bySYSTEM START VIEWorSYSTEM START VIEWS, which now uniformly clear both the stopped and paused states. #103252 (Nikita Mikhaylov). - Added function
regexpPosition(with PostgreSQL-compatible aliasesregexpInstrandregexp_instr) that returns the byte position of the N-th regex match in a string. Supports start offset, return-after-match mode, regex flags, and capture-group selection. #104172 (Abhinav Agarwal). - New functions
isPrimeandisProbablePrimefor primality checks.isPrimereturns an exact result for unsigned integers up toUInt64.isProbablePrimealso supportsUInt128andUInt256; for those wider types,0means definitely composite and1means probably prime. The optional second argument ofisProbablePrime,rounds, controls the confidence (capped at256); the default of25rounds bounds the false-positive rate for a random composite below10^-15, andisProbablePrimeis cancellable. #104234 (Nihal Z. Miaji). #104639 (Alexey Milovidov). #104806 (Nihal Z. Miaji). clearand/clearnow clear the terminal in the clickhouse command-line tools instead of running as a mistaken query. #104318 (Tyler Hannan).- Allow the
filetable function to accept anArray(String)of paths inSELECTqueries. #104442 (Yue). - Add
deterministicandhigher_ordercolumns tosystem.functionstable. #104479 (Pedro Ferreira). - Add an optional encoding variant parameter to
bech32Encode(bech32/bech32m) and a raw decode mode tobech32Decodefor non-SegWit address encoding (e.g. Cosmos SDK, Injective, Osmosis). #98986 (Yash ). - You can now write data in
AvroConfluentformat, which was previously input-only. This enables producing Confluent Schema Registry-framed Avro messages directly from ClickHouse, for example when writing to Kafka. The schema is automatically registered with the registry. Use the newoutput_format_avro_confluent_subjectsetting to specify the subject name. #101935 (János Benjamin Antal). - Added the
prettyPrintJSONfunction to format a JSON string into a human-readable form. Useful for dashboards or reports where prettifying previously required an extra step on the client side. Closes #62523. #102594 (Dmitry Prokofyev). - Added
STRING_AGGas a case-insensitive alias ofgroupConcatfor PostgreSQL / SQL-standard compatibility. #105125 (Alexey Milovidov). - Individual subquery results can now be cached independently using
SETTINGS use_query_cache = trueon specific subqueries, without caching the entire outer query. A new settingquery_cache_for_subqueries = trueenables bulk propagation ofuse_query_cacheinto all subqueries. Note:use_query_cacheon the outer query no longer auto-propagates to subqueries. #99804 (Vincent Voyer). - Added lexer-based syntax highlighting to the query editor in the Web UI (
play.html), modelled afterclickhouse-clientcolors. #105105 (Alexey Milovidov).
Experimental Feature
- Added an experimental web terminal interface at
/webterminalthat provides an interactiveclickhouse-clientsession in the browser over WebSocket. Disabled by default; enable with theallow_experimental_webterminalserver setting. See it here. #100277 (Alexey Milovidov). #105191 (Alexey Milovidov). #105059 (Alexey Milovidov). - The
Kafka2engine (experimental, with Keeper-based offset storage) now supports directSELECTqueries and thekafka_commit_on_selectsetting. #100276 (Alexey Milovidov). WASMUDFs can now coerce more numeric types: smaller integers to wider integers (e.g.Int8toUInt64), and any integer to floating point (e.g.Int32toFloat32). #100435 (Vasily Chekalkin).- Support
LIKEfunction inDELETE FROM system.webassembly_modulesquery. #104397 (Vladimir Cherkasov). - Support geo types for
Iceberg. #103113 (Konstantin Vedernikov). - Add prepared statements functionality to ArrowFlight SQL server. #103047 (Yakov Olkhovskiy).
- Improved KQL parser (for the Kusto language support) robustness by preserving parser depth and backtracks counters across KQL parser stages, so parser limits are tracked consistently for complex KQL queries. #103528 (Yakov Olkhovskiy).
Performance Improvement
- Reuse the Parquet footer metadata cache when reading local Parquet files via the
filetable function orFiletable engine. Previously the cache was only consulted for object-storage backends. #104260 (Alexey Milovidov). - Push
ORDER BY ... LIMIT nthroughLEFT/RIGHTjoins when the sort key only references columns from the side preserved by the join, restricting how many rows the preserved-side input must produce before joining. Controlled by the new settingquery_plan_top_k_through_join(default enabled). #104268 (Alexey Milovidov). - Enable
use_top_k_dynamic_filteringanduse_skip_indexes_for_top_ksettings by default to improve performance ofORDER BY ... LIMIT Nqueries. #99537 (Alexey Milovidov). Restrictuse_top_k_dynamic_filteringto fixed-length sort columns by default, avoiding regressions onORDER BY <var-length-column> LIMIT Nqueries where the per-row threshold comparison cost exceeds the I/O savings. The previous behavior is available via the newuse_top_k_dynamic_filtering_for_variable_length_typessetting. #104216 (Alexey Milovidov). - Use the oversize-arena feature of
jemallocto reduce page faults. #103958 (Nikita Taranov). - Limit simultaneously active streams in
UNION ALLto reduce peak memory usage. #100176 (Alexey Milovidov). - Slightly optimize the userspace page cache. #100300 (Alexey Milovidov). Now the userspace page cache is always better than the OS page cache.
- Cold reads of object storage through the userspace page cache (
use_page_cache_for_object_storage = 1) are now significantly faster, because consecutive cache misses are coalesced into a single HTTP request instead of one request perpage_cache_block_sizeblock. #104230 (Alexey Milovidov). - Speed up the index analysis involving type casting and function application. Closes #55653. #100366 (Alexey Milovidov).
- Speed up huge queries on
Mergetables over a huge number of underlying tables. Closes #32465. #100369 (Alexey Milovidov). - Remove vtable from setting field types, reducing
Settingscopy size by ~28x and improving cache locality via typed-array layout for all settings types. #102269 (Raúl Marín). - Add
max_threads_min_free_memory_per_threadandmax_insert_threads_min_free_memory_per_threadsettings to automatically reduce query parallelism when the server is low on free memory. #100383 (Alexey Milovidov). - Reduce memory usage on low-memory systems (< 4 GiB). #100389 (Alexey Milovidov).
- Added
OptimizeTrivialGroupByLimitPass. For trivialSELECT ... FROM t GROUP BY k LIMIT nqueries (noHAVING,ORDER BY, or window functions), the analyzer now setsmax_rows_to_group_by = n + offsetwithgroup_by_overflow_mode = 'any', so aggregation stops oncendistinct keys have been produced instead of grouping the entire input. Controlled by the new settingoptimize_trivial_group_by_limit_query(enabled by default). #104473 (Amos Bird) (Alexey Milovidov). - Granule-level implicit min-max index for the
_part_offsetand_block_numbervirtual columns, including for projections. Enables fast pruning of granules based on virtual column predicates. #103952 (Mikhail Artemenko). #104746 (Mikhail Artemenko). #105137 (Mikhail Artemenko). - For the
prealloc_serializedfamily of aggregation methods, precompute per-row hashes during the batch-serialization pass and use them to (a) skip rehashing inemplaceKey/findKeyand (b) software-prefetch the next row's bucket. Speeds up multi-key string/serialized aggregation by hiding hash-table cache-miss latency. #104475 (Amos Bird) (Alexey Milovidov). - Query condition cache for
Icebergtables. #102115 (Konstantin Vedernikov). - Optimize
cramersV,cramersVBiasCorrected,theilsU, andcontingencywhen used with window functions. Closes #83521. #93384 (Nihal Z. Miaji). - Added a query optimization that rewrites
tupleElement(dictGet('dict', ('a', 'b', 'c'), key), N)intodictGet('dict', 'a', key), avoiding fetching unnecessary dictionary attributes. Controlled by theoptimize_dictget_tuple_elementsetting (enabled by default). #100186 (Alexey Milovidov). - Enable buffering for sorting steps on the initiator for distributed queries with sorting. #100661 (Nikita Taranov).
- Performance improvement for
partial_mergeJOIN. #100945 (Artem Zuikov). - Slightly reduced memory over-allocation in
partial_mergeJOIN. #100963 (Artem Zuikov). - Optimize allocations/deallocations by caching sampling settings instead of traversing the entire memory-tracker hierarchy. #101267 (Azat Khuzhin).
- Reduce memory allocation overhead during S3 multipart uploads by preallocating internal tracking containers. #101799 (Gagan Dhakrey).
- Add software prefetch in hash join probe phase to reduce memory access latency for large hash tables, controlled by setting
enable_software_prefetch_in_join. #102444 (Xiaozhe Yu). - Optimize
MemoryTrackerlayout, improving its performance by ~25%. #103464 (Azat Khuzhin). - Rewrite
coalesce(a, b, ...) <op> constandifNull(a, b) <op> constpredicates before index analysis so per-column primary key and skip indexes on each argument can prune granules. Controlled by the new settingallow_key_condition_coalesce_rewrite(on by default). #103468 (Manuel). - Significantly improved query performance when reading Iceberg catalogs with large JSON metadata files by optimizing escaped slash processing. #103998 (Mohaidoss).
- Avoid index uncompressed cache overhead when the cache is disabled (server setting
index_uncompressed_cache_size = 0, which is the default). #104063 (Michael Kolupaev). - Fix
ORDER BY ... LIMITqueries with small limit reading excessive granules when combined with a non-selectiveWHEREfilter. Previously, any filter above an in-order read disabled the per-mark-range task split, so the pipeline could not cancel between granules and read the whole part for each stream. #104112 (Vladimir Cherkasov). - Fixed missing hash table sizes cache reuse after reordering JOIN sides. #104131 (Nikita Taranov).
- When
fsync_after_insertis enabled, fsync of part files is now performed in parallel using the IO thread pool, speeding up insert finalization on wide tables. The full ClickBenchhitsload is about 22% faster. #104137 (Alexey Milovidov). - Vectorise
find_first_symbols,find_first_not_symbols,find_last_symbols_or_null,find_last_not_symbols_or_null, andsplitIntoon AArch64 using NEON. Previously these helpers had a SIMD path only on x86 (SSE2 / SSE4.2) and fell through to a scalar loop on ARM. Speeds up TSV parsing by ~2x, URL functions andsplitByCharby ~1.3x on the ClickBenchhitsdataset; very dense JSON parsing (sub-16-byte field cadence) regresses slightly in line with the existing SSE2 trade-off. #104228 (Alexey Milovidov). - Reading data through a trivial
ALIAScolumn (e.g.some_alias['key']wheresome_alias ALIAS m) now goes through the same per-subcolumn read path as referencing the underlying column directly, restoring large I/O savings forMap,Array,TupleandNullablealiased columns. #104245 (Raúl Marín). - Reduced lock contention on the asynchronous remote-FS read path by making the per-query
AsyncReadCounterslockless. #104374 (Nikita Mikhaylov). - Slightly better query plan for projections in-order scan. #103723 (Mikhail Artemenko).
- Extend
optimizeUseNormalProjectionsto also handle a specific case where nothing was filtered but the projection's sorting key can remove the sorting step from the query plan. #104680 (Mikhail Artemenko). - Allow
json.path[]syntax sugar and explicit type hints to work correctly on typedJSONpaths. #99179 (Pavel Kruglov). - Optimize
json.path[N].nested.path(which expands totupleElement(tupleElement(json.path[N], 'nested'), 'path')) intojson.path[].nested.path[N], which reads much less data. #99802 (Pavel Kruglov). - Optimize
SHOW TABLESaccess checks insystem.partsby hoisting database-level grant checks out of the per-table loop. #100860 (Shaohua Wang). - Remove a redundant per-table
SHOW TABLESaccess check in theSELECT name/SELECT database, namefast path ofsystem.tables. #100881 (Shaohua Wang). - Enable JIT compilation on macOS. #100947 (Alexey Milovidov).
- Skip deferring the row policy after
FINALwhen it depends only on sorting-key columns and is deterministic, and skip the correspondingPREWHEREdeferral that the row policy was forcing in that case. #102884 (Yarik Briukhovetskyi). - Added support for
hasAnyandhasAllas filter predicates in text indexes. #103266 (Anton Popov). - Route long-lived MergeTree heap state (per-part and per-table metadata) to a dedicated jemalloc arena, exposed via
jemalloc.mergetree_arena.*async metrics. Reduces default-arena fragmentation in steady-state and keeps per-part survivors from pinning otherwise-decayable pages. #104136 (Raúl Marín). - Improve ZooKeeper client timeout handling under heavy load when many requests are pipelined on a single session. The ZooKeeper client now uses a progress-based timeout: as long as any data is received from the server within
session_timeout_ms, the wait is extended. A hard cap of3 * session_timeout_msper request still bounds caller latency. Closes #100466. #104351 (Antonio Andelic). - Move per-event trace flags into a separate array and allocate them lazily, reducing the overhead of
ProfileEventstracing. #105030 (Azat Khuzhin). - Add
compareTrackAtforColumnDecimal, improving comparison performance forDecimalcolumns. #105110 (Artem Zuikov). - Added a SIMD implementation of
MD5(AVX2/AVX512) that hashes multiple inputs in parallel, improving throughput. #105161 (Joanna Hulboj).
Improvement
- Improve the help output for all ClickHouse applications:
--helpnow consistently returns exit code0, prints tostdout, and a top-levelclickhouse --helplists all subcommands. Adds a--no-sudooption forclickhouse start/restart(useful in Docker), and aclickhouse helpsubcommand. Continuation of #58244 from @qoega. #98148 (Alexey Milovidov). - The default of
input_format_column_name_matching_modeis changed frommatch_casetoauto. Input formats that match input column names against the table schema (JSONEachRow,CSVWithNames,JSONColumns,BSONEachRow,RowBinaryWithNames, etc.) now first try a case-sensitive match and fall back to case-insensitive matching when the case-sensitive match misses. The previous strict behavior is preserved undercompatibility. #104320 (Alexey Milovidov). - Added
STDDEVas a case-insensitive alias ofstddevSampfor PostgreSQL/SQL-standard compatibility. #105120 (Alexey Milovidov). - Added
array_to_stringas a case-insensitive alias ofarrayStringConcatfor PostgreSQL compatibility. #105121 (Alexey Milovidov). - Added
unnestas a case-insensitive alias ofarrayJoinfor PostgreSQL compatibility (function-call form). #105124 (Alexey Milovidov). - The progress bar in
clickhouse-clientnow shows temporary data on disk usage (e.g. for external sort, aggregation, or JOIN) next to RAM, including a per-host breakdown for distributed queries. #105190 (Alexey Milovidov). - Added
system.predicate_statistics_log, a new sampled log of predicate filter selectivity and MergeTree index-granule pruning per query. Disabled by default; enable via thepredicate_statistics_sample_rateserver setting. Needed for automatic index and projection recommendations. #98727 (Yarik Briukhovetskyi). - Allow skipping local shard with missing table when
skip_unavailable_shardsis enabled. #100141 (Alexey Milovidov). - Add startup warnings (visible in
system.warnings) when a Linux mdraid array is being resynchronized or is in a degraded state, as both can affect disk I/O performance or indicate disk failures. #100941 (Alexey Milovidov). - WASM UDFs now appear in
system.functionswith correctorigin(WasmUserDefined),syntax,arguments, andreturned_valuecolumns populated from their ClickHouse type metadata. Previously they were either missing or listed with the wrong origin as duplicates. #101053 (Vasily Chekalkin). - The
generate_seriestable function now supports negative step values for generating descending sequences, e.g.SELECT * FROM generate_series(99, 0, -1). #101056 (Alexey Milovidov). - Fix
Context has expiredexceptions raised by some functions (dotProduct,formatRow,structureToCapnProtoSchema/structureToProtobufSchema, user-defined functions) when used in deferred execution paths such asDEFAULT/MATERIALIZEDexpressions and table engine settings, by ensuring those functions hold a strong context where required. #101109 (Alexey Milovidov). - Fix spurious
Cache limits violatedlogical errors on priorities created with zero limits (such as the per-query filesystem cache priority used whenenable_filesystem_query_cache_limitis on). #101428 (Alexey Milovidov). - Auto-detect the region for
s3expressendpoints. #101520 (Pradeep Chhetri). - Support field ids for data files in
Icebergwrites. Closes #102322. #102362 (Konstantin Vedernikov). - The left panel in the web UI (
play.html) now scrolls independently, stays visible when the page is scrolled, and clicking a table scrolls to the query area. #102498 (Alexey Milovidov). - Allow opening the Play UI in a new tab via Ctrl/Cmd/Shift+click or middle-click on the ClickHouse logo in the left panel. #102501 (Alexey Milovidov).
- New metrics to track memory used by projection primary keys and projection index granularity across all tables. #102587 (Narasimha Pakeer).
- Apply
max_network_bandwidth_for_userandmax_network_bandwidth_for_all_usersto remote filesystem reads/writes. #103080 (Azat Khuzhin). - Improve the resilience of backups when Refreshable Materialized Views are constantly refreshed by making decisions based on the snapshotted tables' state rather than a global one. #103384 (Nikita Mikhaylov).
SELECT * FROM system.databasesnow always lists data lake catalog databases regardless of theshow_data_lake_catalogs_in_system_tablessetting. Previously they were hidden by default, which was inconsistent withSHOW DATABASESthat always showed them. #103444 (Alsu Giliazova).- Align the default of the server setting
concurrent_threads_soft_limit_ratio_to_coresin code with the shippedconfig.xmlvalue (2), so the defaultmax_min_fairconcurrent threads scheduler caps query processing threads at 2x cores out of the box even when the shippedconfig.xmlis not used. #103446 (Alexey Milovidov). - Improved sanitizer robustness in parser and string-function edge cases by handling empty input in
getURLScheme, avoiding null-pointer arithmetic inLexer::nextTokenmax_query_sizechecks, and short-circuiting UTF-8 subsequence evaluation on empty haystacks before decoding. #103489 (Yakov Olkhovskiy). - Improved correctness of monotonicity inference for
divide(0, x)andintDiv(0, x): previously the functions were unconditionally reported as monotonic, but0 / xis non-monotonic on any range that includes 0 because0 / 0is undefined (NaN/Inffordivide, division-by-zero exception forintDiv). The false claim causedKeyCondition::applyMonotonicFunctionsChainToRangeto produce ranges withleft > right, which tripped aLOGICAL_ERRORInvalid binary search result in MergeTreeSetIndexin debug builds when anIN/NOT INexpression on the primary key wrapped the key individe(0, key)orintDiv(0, key). Release builds were unaffected — the assertion is gated by#ifndef NDEBUG. #103621 (Groene AI). - Replace the
HTTPConnectionPool*TCP{Rcv,Snd}BufBytes_{p50,p75,p90,p95}async metrics with a bucket-based histogramhttp_pool_tcp_buf_bytes(labelsgroup,direction) insystem.histogram_metrics. Per-group total async metrics are preserved. #103704 (Sema Checherinda). - The server settings
{disk,storage,http}_connections_{rcvbuf,sndbuf}are now reported as changeable without restart insystem.server_settings. Their values can be updated viaSYSTEM RELOAD CONFIG; the runtime application path was already in place since #100478. #103772 (Sema Checherinda). - Add support for resolved symbols (
Array(String)) inflameGraph. #103816 (Azat Khuzhin). - CLI client can now specify
<rainbow_parentheses>false</rainbow_parentheses>in its config in environments where terminal colors clash with the parentheses (similarly,clickhouse formatnow has--no_rainbow_parentheses). #103851 (Larry Snizek). - Fix
MultiVolnitskyUTF-8 case-insensitive search by rolling back partialputNGraminserts on failure and switching failed needles to fallback searchers, avoiding inconsistent state. #103864 (Yakov Olkhovskiy). - Implement
sched_getcpuviarseqTLS in glibc-compatibility musl. #104016 (Azat Khuzhin). - Replicated refreshable materialized view in APPEND mode will no longer refresh twice if connection to zookeeper was briefly lost during refresh. #104051 (Michael Kolupaev).
- Allow Distributed tables without an explicit column list to validate sharding keys against the inferred remote table structure. #104111 (Yue).
- Fix REST catalog with
Azureabfsspath. #104120 (Konstantin Vedernikov). - Honor
role_arnandrole_session_nameauth settings in the Keeper S3 snapshot client, allowing snapshot uploads to use STSAssumeRole-based authentication. #104140 (Alexey Milovidov). - Fix a memory leak when running queries with
MATERIALIZEDCTEs. #104153 (Alexey Milovidov). - Fix
lowerUTF8/upperUTF8exception when processing large non-ASCII data sets (e.g. during text-index builds) where the accumulated output buffer would exceed 2 GiB; reject excessively long single rows with a clear error. #104229 (Shaohua Wang). - Harden MergeTree column-statistics loading against transient I/O failures to prevent permanently disabling statistics-based optimizations for affected parts. #104372 (zoomxi).
INSERT INTO ... SELECT FROM input(...)no longer requires theCREATE TEMPORARY TABLEgrant. #104470 (Alexey Milovidov).- Added a new MergeTree setting
concurrent_part_removal_threshold_for_remote_disk(default16) that is used instead ofconcurrent_part_removal_thresholdwhen at least one part being removed is stored on a remote disk. The previous threshold of100could makeDROP TABLEand other part-removal operations on object storage backends stall for tens of seconds because removals were performed serially even though each one is a separate network round-trip. The new setting causes the parallel removal path to be entered much sooner on remote storage, while leaving local-disk behavior unchanged. #104676 (Groene AI). - New setting
defer_partition_pruning_after_final(default1) makes the 26.3-introduced behavior of skipping partition pruning underFINALopt-out. Set it to0to restore pre-26.3 partition pruning — substantially faster on event-log workloads where same-PK rows cannot span partitions.compatibility = '26.2'flips it to0automatically. #104705 (Nikita Fomichev). - Fix
intExp2returning wrong results for out-of-range inputs (shifts>= 64under JIT, and integers with magnitude exceedingINT_MAXon both code paths). #105054 (Raúl Marín). - Quote shell arguments built from CLI options and parsed input in
clickhouse installandclickhouse git-importso paths, user/group names, and commit hashes containing whitespace or shell metacharacters are handled correctly. #105232 (Raúl Marín). - The
Aliastable engine is now non-experimental and available without theallow_experimental_alias_table_enginesetting. #103488 (Alexey Milovidov). - Added
--queries-formatoption toclickhouse-benchmarkto choose between the default tab-escaped one-query-per-line input (tsv) and parsing standard input as a script of multiple queries separated by;(script). #99972 (Aleksandr Musorin). - The element-wise tuple operators
tuplePlus,tupleMinus,tupleMultiply,tupleDivide,tupleModulo,tupleIntDiv, andtupleIntDivOrZeroare now variadic and accept two or more tuples of the same size, applied element-wise as a left-fold. They previously accepted exactly two arguments only. #104659 (Aruj Bansal). - Added a new built-in web UI at
/processors-profilethat visualizes the pipeline of any pastSELECTquery as a heatmap, sourced fromsystem.query_logandsystem.processors_profile_log. Each processor is colored by itselapsed_usand shows per-processor stats (rows, bytes, wait times) on hover. #104614 (Nikita Mikhaylov). - Setting
query_plan_use_logical_join_step(and its aliasquery_plan_use_new_logical_join_step) is now obsolete and has no effect; the logical join step is always used. #104017 (Vladimir Cherkasov). - The
userinput onplay.htmland the other built-in web pages (dashboard.html,jemalloc.html,merges.html,binary.html,webterminal.html) is no longer pre-filled with the literal textdefault. It now shows auserplaceholder hint and is empty by default. When left empty, the page does not send auser=URL parameter (and the WebTerminal auth JSON omits theuserfield), so the server applies its usual fallback to thedefaultuser — and HTTP credentials supplied via other channels (X-ClickHouse-User, HTTP Basic, per-handler<handler><user>configuration) are no longer overridden. #105254 (Alexey Milovidov). ORCreader: decouple offset-based read (readBigAt) fromuse_prefetch, so EC-encoded data onHDFScan be read correctly even whenuse_prefetch = false(e.g. by Gluten). #103348 (zhanglistar).- Files downloaded from
play.htmlwith theCSVWithNamesformat now use the.csvfile extension. #103737 (JackFielding). - More input validation for the BigLake catalog. #105117 (Konstantin Vedernikov).
Bug Fix (user-visible misbehavior in an official stable release)
- Fix inconsistent formatting by remembering if an expression was parenthesized. #92340 (Alexey Milovidov).
- Fix accurate comparison between Decimal and Float types. #94293 (zoomxi).
- Allow positional arguments in distributed queries. #94359 (simonmichal).
- Fix assertion failure in
DatabaseCatalog::updateDependencieswhen dropping and recreating a materialized view with the same name; also fix view dependencies being silently lost duringRENAME TABLEorEXCHANGE TABLESwhen referential dependencies were empty. #98779 (Alexey Milovidov). - Fixed a server abort (assertion failure in
DatabaseCatalog::getTableImpl) that occurred when creating a table viaON CLUSTERwith a UUID identical to an existing database's UUID. #98861 (xiaohuanlin). - Fixed usage of skip indexes on data read (with enabled setting
use_skip_indexes_on_data_read) and existing patch parts created by lightweight updates. #99543 (Alexey Milovidov). - Fix "Not-ready Set" exception when a filter with
IN (subquery)is moved to PREWHERE by the query optimizer. #100375 (Alexey Milovidov). - Fix "Cannot find column" error when combining
ADD COLUMNwithRENAME COLUMNin a singleALTER TABLEstatement. #100387 (Alexey Milovidov). - Fix views with mixed
UNIONandINTERSECT/EXCEPToperators returning wrong results afterDETACH/ATTACHor server restart. #100390 (Alexey Milovidov). - Fix "Trying to execute PLACEHOLDER action" exception that could occur during stress testing with the AST fuzzer when a correlated subquery appeared in an IN clause. #100398 (Alexey Milovidov).
- Fix logical error exception when inserting into an Iceberg table with a
Datecolumn partitioned byyear,month, ordaytransforms. #100404 (Alexey Milovidov). - Fix skip index being used with incompatible data after
ALTER TABLE MODIFY COLUMNchanges the column type, which could cause server crashes in sanitizer builds or incorrect query results. #100526 (Alexey Milovidov). - Fix credential leak in
query_logforpaimonCluster,paimonS3Cluster,paimonAzureCluster, anddeltaLakeS3table functions. #100529 (JIaQi Tang). - Fix
DROP TABLEon Kafka engine tables potentially hanging indefinitely due to a deadlock inrd_kafka_consumer_close. #100604 (Alexey Milovidov). - Replace the hardcoded
source_table_engineslist with runtime lookup viaStorageFactoryandDatabaseFactory. Addsource_access_typetoDatabaseFactory::EngineFeaturesso thatCREATE DATABASEwith source engines (PostgreSQL, MySQL, S3, etc.) requires the same source grants asCREATE TABLE. FixesGRANT TABLE ENGINE ON *failing withtable_engines_require_grant=false. Closes #71544. #100746 (pufit). - Fix server crash when reading from a table whose
ALIAScolumn contained a correlated subquery nested inside a function call (e.g.ALIAS toString(intDivOrZero(x, (SELECT ...)))).CREATE TABLEandALTER TABLEnow reject any subquery at any depth inDEFAULT/ALIAS/MATERIALIZEDcolumn expressions withTHERE_IS_NO_DEFAULT_VALUE. Previously, the shallow validation accepted nested subqueries, so the correlated case crashed at read time and the nested non-correlated case appeared to work but could lead to unexpected behavior; both are now rejected at DDL time. #100753 (Groene AI). - Fixed a server crash (
Logical error: Bad cast from type DB::FunctionNode to DB::ColumnNode) that could occur when using queries with correlated subqueries on tables that haveCONSTRAINT ... ASSUMEdefinitions, whenoptimize_substitute_columnsandconvert_query_to_cnfsettings are enabled. #100756 (Groene AI). - Fix an exception that could occur when inserting a row into a JSON column where the row introduced a new dynamic field alongside a typed field with an incompatible value, and the column was subsequently used as a GROUP BY key. #100758 (Jimmy Aguilar Mena).
- Fix workload IO scheduling being silently bypassed for S3/object-storage writes that go through the
DiskObjectStorageTransactionpath (used bys3_with_keeperdisks and explicitly whenuse_fake_transaction=false). Previously, INSERT writes into MergeTree tables on such disks ignoredCREATE RESOURCE/CREATE WORKLOADthrottling because the resource link was never injected intoWriteSettingsfor the transactional write path. #100777 (JIaQi Tang). - Fix shared schema-cache collision between
ProtobufandProtobufList: reading a message first asFORMAT Protobufand then asFORMAT ProtobufListcould fail becauseProtobufListforced the cached schema into its envelope form.ProtobufListnow falls back to the cached message type when no envelope schema is available. #100849 (Callum Cooper). - Fix heap-buffer-overflow in Rust CXX bridge due to
std::exceptionABI mismatch. #100931 (Azat Khuzhin). FunctionVariantAdaptornow throwsILLEGAL_TYPE_OF_ARGUMENTwhen allVariantalternatives are incompatible with a function, instead of silently returningNullable(Nothing). Previously, aWHERE function(variant_col)predicate where no alternative type was compatible would return 0 rows with no error, while the equivalentSELECTcontext already threw correctly. #100939 (Vasily Chekalkin).TRUNCATE ALL TABLESno longer fails when the database contains views. #100943 (Alexey Milovidov).- Fix the
optimize_rewrite_array_exists_to_hasoptimization to correctly handle type-incompatible cases (e.g. Date vs String) and re-enable it by default. #100944 (Alexey Milovidov). - Fix S3 settings priority so that
storage_configurationdisk settings override global<s3>section, and user/profile/query-level settings override both. #100975 (Alexey Milovidov). - Fix sparse serialization losing the sign of negative zero (-0.0) for BFloat16, Float32, and Float64 columns. #100983 (Takumi Hara).
- Fixed two bugs in the WKT geometry parser used when reading WKT-encoded GeoParquet and Arrow files:
MULTILINESTRINGgeometries were incorrectly parsed asPolygon(causing an exception for typed columns and silent data corruption for mixedGeometrycolumns), and a malformed WKT string with no type keyword triggered undefined behaviour instead of a clean error. #100997 (Vasily Chekalkin). - Fix
grouping/GROUPING SETSqueries on Distributed tables with a single shard that failed with "Method executeImpl is not supported for 'grouping' function". #101030 (Alexey Milovidov). - Fix
LOGICAL_ERROR"Column identifier is already registered" in the planner that could occur when the same table expression was processed multiple times. #101048 (Alexey Milovidov). - Fix LOGICAL_ERROR exception "Column identifier is already registered" when
additional_result_filtersetting is used with UNION or EXCEPT queries. #101051 (Alexey Milovidov). - Fixed server crash (Logical error: Bad cast from ColumnVector to ColumnNullable) when using
* APPLYwith aggregate functions andgroup_by_use_nulls=1with GROUPING SETS, ROLLUP, or CUBE. #101062 (Groene AI). - Fix infinite loop when
input_format_csv_skip_first_linesorinput_format_tsv_skip_first_linesexceeds the number of lines in the file. #101111 (Alexey Milovidov). - Fix out-of-bounds access in lazy materialization optimization that could cause an exception in debug builds. #101144 (Alexey Milovidov).
- Fix type inference in recursive CTEs: column types are now iteratively widened via
getLeastSupertypeacross the non-recursive and recursive sides of theUNION ALLuntil convergence, preventing integer overflow in expressions likex + 1. #101155 (Alexey Milovidov). - Clamp MergeTree compress block size settings (max_compress_block_size, min_compress_block_size, marks_compress_block_size, primary_key_compress_block_size) to 256 MiB to prevent server crash when extreme values are set via CREATE TABLE SETTINGS. #101159 (Groene AI).
- Fix a LOGICAL_ERROR crash in
QueryAnalyzer::resolve()when a ROW POLICY uses a scalar subquery in itsUSINGclause (e.g.USING (SELECT 1)). Closes #100695. #101263 (Groene AI). - Fix undefined behavior in
MergeTreeDataPartWriterCompact::cancelwhen a stream allocation fails. #101292 (Alexey Milovidov). - Fixes a case where timezone was not included during the assignment in the ALTER statement. Closes #101328. Related https://github.com/ClickHouse/ClickHouse/pull/100647. #101403 (Yarik Briukhovetskyi).
- Fix server crash (LOGICAL_ERROR) for INSERT SELECT queries with ORDER BY ALL when the SELECT pipeline produces multiple streams. #101443 (Groene AI).
- Fix incorrect query results caused by join reordering pushing an INNER JOIN filter (referencing only the preserved side of an outer join) into the outer join’s ON clause. #101504 (Vladimir Cherkasov).
- Skip applying lazy materialization for plans with arrayJoin, which could lead to limit not being respected. Close #101608. #101644 (Vladimir Cherkasov).
- Fix incorrect JOIN query results when
mergeFilterIntoJoinConditionoptimization silently dropped a WHERE equality condition with mismatched types. #101652 (Xiaozhe Yu). - Fix the
errortest hint not working for syntax/parsing errors — previously-- { error SYNTAX_ERROR }on a malformed query would fail with "Expected server error" instead of matching the client-side parse error. #101675 (Groene AI). - Fix
INTO OUTFILE ... TRUNCATEnot actually using atomic rename — the write went directly to the original file instead of a temp file, so on query failure the original content was destroyed. Now the data is written to a temp file and renamed only on success. #101884 (Pablo Marcos). - Fixed an exception
Unsupported DeltaLake type: varchar(n)when reading Delta Lake tables whose schema contains varchar(n) or char(n) column types. These types are now mapped to String, consistent with how the Delta Lake protocol stores them as plain byte arrays in Parquet. #101973 (Flavio Malavazi). - Fix silent data loss when reading tar archives from S3 with
schema_inference_mode=unionand heterogeneous Parquet schemas — the Parquet metadata cache incorrectly reused the first file's metadata for all subsequent files in the archive. #101990 (Ahaan Limaye). - Fix server crash (LOGICAL_ERROR) when executing ALTER TABLE UPDATE/DELETE on Iceberg tables when no prior SELECT or INSERT was done on the table in the same server lifetime. #102113 (Alexey Milovidov).
- Fix possible crash when an ALTER query executed on tables from in-memory database (e.g. temporary tables). #102360 (Den Kalantaevskii).
- Fixed
formatQueryproducing duplicate grants likeGRANT FILE ON *.*, FILE ON *.* TO xinstead ofGRANT FILE ON *.* TO xwhen formatting backward-compatible READ/WRITE grants on the same source. #102411 (Groene AI). - Fix lost parallelism for aggregation after read-in-order queries when
max_streams_to_max_threads_ratiois greater than 1. #102467 (Alexey Milovidov). - Fixed a crash (
LOGICAL_ERROR: Unknown virtual column) when selecting subcolumns (like.nullfor Nullable,.size0for Array, tuple elements, or map keys/values) from a Buffer table engine. #102470 (Groene AI). - Fix exception "Cannot fold actions for projection" in join reorder optimization when a LEFT/RIGHT JOIN with
join_use_nullsis combined with other joins involving more than two tables. #102516 (Alexey Milovidov). - Fixed silent overflow in scalar pointwise operations on numericIndexedVector (e.g.
numericIndexedVectorPointwiseAdd) when the scalar is out of range. Such inputs now raiseINCORRECT_DATAinstead of returning corrupted values. #102546 (FriendLey). - Fix inconsistent AST formatting for INSERT with SAMPLE and query-level OFFSET. Closes #102523. #102547 (zoomxi).
- Fix
LOGICAL_ERRORexception ingroupConcatwhen deserializing a malformed aggregate function state. #102558 (Christoph Wurm). - Now we do not accept garbage at the end of Time64 CSV values with
input_format_csv_use_default_on_bad_values=0. Closes #102490. #102596 (Yarik Briukhovetskyi). - Fix UNKNOWN_ELEMENT_OF_ENUM exception when inserting default value to JSON column with Enum typed paths. Closes #102359. #102687 (Pavel Kruglov).
- Fix columns_substreams.txt corruption during column rename in some cases. Closes #102259. #102689 (Pavel Kruglov).
- Fix inserting into Time data type during JSON parsing. Closes #102016. #102690 (Pavel Kruglov).
- Fix hex encoding of content sample in cached schema filenames. Closes #101904. #102703 (Pavel Kruglov).
- Fixed sort order violation (crash in debug, silent data corruption in release) during
SummingMergeTreemerge when theORDER BYkey is a hash expression over aFloat32column containing signaling NaN values. #102791 (Groene AI). - Make
DETACH DATABASE ... SYNCand other operations that callwaitDetachedTableNotInUsecancellable viaKILL QUERYand responsive to server shutdown, preventing indefinite hangs when a concurrent query holds a table reference. #102804 (Antonio Andelic). - Fixed possible incorrect result of
ANY RIGHT JOIN. #102893 (Nikita Taranov). - Fix S3 requests failing with
ios_base::clear: unspecified iostream_category errorinstead of being retried, caused by PocoBufferedStreamBuf::flushBuffernot handling short writes from the socket layer. #102894 (Sema Checherinda). - Fix
input('auto')table function failing via HTTP interface in INSERT SELECT queries. #102902 (Miсhael Stetsyuk). - Disable trivial LIMIT optimization with row policies/additional_table_filters (to allow parallel index analysis). #102921 (Azat Khuzhin).
- Hide secret key in
HMACSQL function. Fix #102927. #102997 (Mikhail f. Shiryaev). - Fix
MULTIPLE_EXPRESSIONS_FOR_ALIASexception raised on distributed queries that reference the samequantilecall multiple times (e.g. inSELECT,HAVING, andORDER BY) withoptimize_syntax_fuse_functionsenabled. #103014 (tanner-bruce). - Fixes a case found by CI where a not-ready set was passed when the filter depends on the left-side column. Closes #102966. #103029 (Yarik Briukhovetskyi).
- Fix castOrNull to JSON in some cases. Closes #101818. #103036 (Pavel Kruglov).
- Fix
SELECT DISTINCTsilently returning incomplete results when an aggregate projection matched the query and some parts of the table had no projection data (e.g. the projection was added on a table that already held data, andMATERIALIZE PROJECTIONwas not run). Closes #102951. #103052 (Nihal Z. Miaji). - Fix
TOO_FEW_ARGUMENTS_FOR_FUNCTIONexception when aWHEREpredicate such asAND(OR(A, A), A)collapses to a single top-level argument during common expression extraction in the analyzer. #103072 (Peng). - Fix a logical error
Function writeSlice expects same column types for GenericArraySlice and GenericArraySinkraised when evaluatingif/ifNullover tuples, maps, or arrays containing aQBitelement.ColumnQBit::structureEqualsincorrectly compared the inner tuple of oneQBitcolumn against the outer wrapper of the other, so structurally identicalQBitcolumns were reported as different. #103084 (Groene AI). - Make
DETACH DATABASEwithdatabase_atomic_wait_for_drop_and_detach_synchronouslyrespectKILL QUERYinstead of hanging indefinitely when a table reference is held. #103095 (Alexey Milovidov). - Fix segfault when deleting WASM module using non-identifier predicate (e.g.
WHERE 1=1). #103101 (Joe Redfern). - Fix backward compatibility break where old clients fail with
UNEXPECTED_PACKET_FROM_SERVERwhen inserting into a newer server viaremote()or distributed tables, caused by unconditionalsendProgressat the end ofprocessInsertQuery. #103148 (Sema Checherinda). - IN with non-constant tuple second argument must not CAST tuple elements down to the LHS type, this can overflow. Closes #103055. #103169 (Yarik Briukhovetskyi).
- Fix use-of-uninitialized-value in protocol function. #103187 (Pavel Kruglov).
- Fix
LOGICAL_ERROR(Bad cast … to ColumnLowCardinality) during MergeTree index analysis when aWHEREclause compares aLowCardinalitykey column with a constant cast to a type that contains nestedLowCardinality(for exampleVariant(LowCardinality(Date), String)). #103211 (Groene AI). - Fix
Logical error: 'index < bucket_count'in thetimeSeries*ToGridaggregate function family (e.g.timeSeriesResampleToGridWithStaleness,timeSeriesChangesToGrid,timeSeriesResetsToGrid,timeSeriesRateToGrid) when called with extreme timestamp parameters that would overflow signed 64-bit arithmetic in the bucket count computation. Also cap the total number of grid buckets at 16 million to prevent accidental large-memory allocation from adversarial inputs. #103223 (Groene AI). - Fix
Logical error: 'Port is already connected'exception during pipeline expansion in the lazyFINALpath forReplacingMergeTree. The bug affected queries withquery_plan_optimize_lazy_final = 1whenReadFromMergeTree::initializePipelineinserted internal transforms (e.g. aResize) that wired the sub-pipeline's processors together, causingLazyUnorderedReadFromMergeTreeSource::expandPipelineto try to connect output ports that were already connected. #103230 (Groene AI). - Fix wrong results from
LIMIT BYandDISTINCTwhen the input is aUNION ALLof sorted subqueries. The query plan optimizer incorrectly treated such a union as globally sorted, causing extra rows to be returned. #103231 (Nihal Z. Miaji). - Fix possible crash during statistics calculation in Map type with lazy replication. Closes #102390. #103273 (Pavel Kruglov).
- Fix a data race for ClickHouse, MySQL, PostgreSQL and XDBC dictionary sources where
clone() constreads from andisModified() constwrites to the sameinvalidate_query_responsestring. #103277 (Miсhael Stetsyuk). - Fix incorrect monotonicity detection for
Date32. Closes #101265. #103283 (Yarik Briukhovetskyi). - Cap pre-auth TCP Hello packet strings to 64 KB and add
handshake_timeout_millisecondsserver setting to limit total handshake time, preventing unauthenticated clients from consuming excessive memory or holding threads indefinitely. #103284 (Sema Checherinda). - Fix Parquet ColumnIndex stats min_value > max_value for String columns. #103334 (Saurabh Kumar Ojha).
- Fix incorrect handling of NULL rows for
Nullable(Tuple(...))inputs inflattenTupleandtupleToNameValuePairs.flattenTuplenow preserves the outer null map so NULL rows stay NULL.tupleToNameValuePairsnow changes the result's value type toNullable(T)when possible when the input isNullable(Tuple(...)), so NULL rows produce[('a', NULL), ('b', NULL)]instead of[('a', 0), ('b', 0)]. When the element type cannot be wrapped inNullable(e.g.Array), default values are used instead of NULL. Closes #103312. #103383 (Nihal Z. Miaji). - Check for malformed flattened Dynamic data in Native format. #103392 (Pavel Kruglov).
- Fix stale RPC causing replication stall after snapshot sync. #103406 (Seva Potapov).
- Fix a
LOGICAL_ERROR"Cannot pop N rows from X" that aborted the server (in debug / sanitizer builds) when reading a malformed BSON document containing a value whose BSON type is incompatible with the target column type inside aNullable(T)orArray(Nullable(T))column. The malformed row now produces a cleanILLEGAL_COLUMNexception as intended. #103418 (Groene AI). - Fix a server abort in
arrayFillandarrayReverseFillwhen applied to anArray(String)column whose first row is empty together with a constant-false lambda. The aggregate / sub-array loop underflowed asize_tindex toSIZE_MAX, which then caused an out-of-bounds read insideColumnString::doInsertManyFrom. Same bug family as #12263. #103424 (Groene AI). - Fixes ACCESS_DENIED / UNKNOWN_TABLE in downstream APPEND RMVs with SQL SECURITY DEFINER when an upstream REPLACE RMV's EXCHANGE flips the target storage identity mid-resolution. #103427 (Alexander Gololobov).
- Populate
_timecolumn fromurltable function. #103437 (Nikita Taranov). - Fix potential out-of-bounds read in the
ALPcodec decompression path when processing malformed input with an invalid bit-width. #103457 (Raufs Dunamalijevs). - Fix a bug where
SYSTEM SYNC FILESYSTEM CACHE '<name>' ON CLUSTER ...could lose the cache name while formatting the query, causing remote nodes to sync all filesystem caches instead of only the requested cache. #103469 (Asish Kumar). - Fix processing of URL-encoded path in
deltaLakeAzure. Closes #103509. #103525 (Smita Kulkarni). - Fix heap-use-after-free in multiplying an
AggregateFunctionstate by an integer (e.g.quantilesExactState(...) * N). The exponentiation-by-squaring loop merged the state with itself, which is undefined when the aggregate function'smergereallocates its internal storage. Closes STID 0988-40af. #103536 (Groene AI). - Fixed a rare
LOGICAL_ERROR"Part X intersects previous part Y" raised duringReplicatedMergeTreetable startup when two empty unexpected parts on disk had overlapping but non-containing block ranges. The exception aborted the table-attach thread and prevented the table from coming up. #103537 (Groene AI). - Fix
Logical error: Incorrect mark rows for part ...(debug-only assertion) that was triggered by mutations onMergeTreetables with non-adaptive index granularity (index_granularity_bytes = 0) whose last data mark was incomplete (most reliably reproduced viaDETACH/ATTACHfollowed by a lightweightDELETE). #103538 (Groene AI). - Fix
clickhouse-localreturning 0 rows silently when reading from/procand/syspseudo-files via thefile()table function (e.g.SELECT * FROM file('/proc/cpuinfo', 'RawBLOB')). #103548 (Ashrith Bandla). - Fixed handling of the
max_string_lengthargument for theGenerateRandomtable engine. #103550 (Alex Kuleshov). - Fix masking nested credentials in logs. #103552 (Vitaly Baranov).
- Fix SVE detection using SVE instructions when unavailable. #103568 (Raúl Marín).
- Fix
GenerateRandomstorage args parsing. #103574 (Konstantin Bogdanov). - Fix infinite loop on
WITH FILLfor data starting with ±inf. #103580 (Konstantin Bogdanov). - Fix
JSONExtractinto aVarianttype silently truncating fractional JSON numbers. Previously,JSONExtract('{"x": 3.14}', 'x', 'Variant(Int64, Float64)')returnedInt64=3andJSONExtract('{"x": 3.14}', 'x', 'Variant(String, Int64)')returnedInt64=3, dropping the fractional part. The fractional value is now preserved losslessly: aFloat64/Decimalmember claims it when present, otherwise aStringmember captures the original JSON.Varianttypes containing only integer members (e.g.Variant(Int64, Int32)) and direct integer extraction (JSONExtract(json, 'Int64'),JSONExtractInt, etc.) are unchanged. #103620 (Groene AI). - Fix
SYSTEM INSTRUMENT REMOVEwithout arguments producingstd::bad_optional_access(error code 1001) instead ofSYNTAX_ERROR(error code 62). #103622 (Pablo Marcos). - Fix logical error / undefined behavior in
windowIDandtumblewindow view when called with a timezone string as the 3rd argument. #103641 (Alexey Milovidov). - S3 client logging now treats HTTP 400 responses that include a non-empty x-amz-bucket-region header (wrong SigV4 signing region) as an informational wrong-region case with a clearer log line instead of the generic error-style path. The STS web identity credentials provider is added to the S3 credentials chain only when web identity is configured, which reduces spurious warnings for deployments that do not use it. Closes #99140. #103673 (MeltonSmith).
- Fix
SYSTEM SYNC REPLICA <db>.<tbl> IF EXISTSto silently succeed when the database does not exist, matching the existing behaviour for a missing table and the precedent set byDROP TABLE IF EXISTS. Previously the query threwUNKNOWN_DATABASEdespiteIF EXISTS. Closes #103629. #103689 (Groene AI). - Fix logical error
Arguments of 'plus' have incorrect data typesthrown byFunctionBinaryArithmetic::executeImpl2when aMergeTreetable hadArray(LowCardinality(...))in its sort key and aWHEREclause usedplus/minusbetween that column and anArrayconstant of a different element type.KeyCondition::getMonotonicityForRangenow stripsLowCardinalityrecursively before invoking the inner numeric dispatch. #103701 (Groene AI). - Fix dynamic cache resize race in 26.1+. #103702 (Kseniia Sumarokova).
- Fixed an issue where text and bloom_filter skip indices on
ALIAScolumns whose expression contained a lambda with captured constants (e.g.arrayMap((k, v) -> concat(k, '=', v), mapKeys(m), mapValues(m)))were silently ignored. #103708 (Anton Popov). - Fix
positionandpositionCaseInsensitivewith astart_posclose toUINT64_MAXgetting stuck or causing a segmentation fault due to overflowing pointer arithmetic. #103766 (Raúl Marín). - Fixes undefined behavior while parsing dateTime with a double fractional part. #103773 (Yarik Briukhovetskyi).
- Fixed a data-correctness regression in 26.x where JIT-compiled
ifandmultiIfwith aDecimalresult type and a non-Decimal(integer or float) literal in one branch silently returned a value10^scaletoo small. The slow (non-JIT) path was unaffected. Workaround on affected versions:SET compile_expressions = 0. #103809 (Groene AI). - Fixes forwarding the tokenizer from the text index to supported functions. #103826 (Elmi Ahmadov).
- Fix wrong results from
numbers,generate_series, and similar range-honoring sources when theWHEREclause usesINorNOT INover a tuple whose elements deduplicate to a single key column (for example,WHERE tuple(number, number) NOT IN (tuple(1, 2))). Closes #103660. #103835 (Groene AI). - Keep the auto-spilling hash join's actual memory peak under
max_bytes_before_external_join. Previously, statistics-driven preallocation, in-place hash table doubling, and unboundedGraceHashJoinin-memory buckets could each push the query past the configured cap and tripMEMORY_LIMIT_EXCEEDED. #103838 (Alexey Milovidov). - Fix a hang in
clickhouse-localshutdown when system logs (such astext_logorfilesystem_cache_log) are configured.SystemLogs::flushImplwas callingBaseDaemon::instance().flushTextLogs(), which throwsstd::bad_castoutsideclickhouse-serverand left the saving threads running untilpthread_cond_destroyblocked the destruction of the system log queues. #103874 (Alexey Milovidov). - Reject
MATERIALIZEDCTE queries whose body resolves to different inferred column types in different references with a clearTYPE_MISMATCHerror instead of crashing the server with aBad castLOGICAL_ERROR. This previously happened when the CTE body referenced identifiers from outer scope (for example an alias from the calling subquery's projection) that were inlined as different constants per reference. #103879 (Groene AI). - Fix a use-of-uninitialized-value in the JOIN-conversion query plan optimizers (
tryConvertAnyOuterJoinToInnerJoin,tryConvertAnyJoinToSemiOrAntiJoin) when the filter on top of anANYOUTERJOINcontains a non-deterministic function such asrand,now, orrowNumberInAllBlocks. The optimizer no longer attempts to constant-fold such filters and leaves the JOIN unchanged, which also prevents incorrect conversions toINNER/SEMI/ANTI JOINthat could silently drop rows. #103880 (Groene AI). - Fix a use-after-free in
StorageKafka2that could crash the server when a Keeper session is replaced while the consumer is holding ephemeral topic-partition locks. #103890 (Groene AI). - Fixed a
LOGICAL_ERROR"Primary key type mismatch" thrown when joining anEmbeddedRocksDBtable viaJOIN ... USING (key)against a subquery whose key column has a different type (e.g.Nullable(UInt64),Int64,Decimal) than the storage's primary key. The planner now declinesDirectKeyValueJoinon type mismatch and falls back toHashJoin, which handles the type conversion. #103928 (Groene AI). SET max_threads = DEFAULT(and the same formax_final_threadsandmax_parsing_threads) no longer loses the auto state. Previously, after resetting one of these settings,system.settingswould report the resolved core count (e.g.32) instead of'auto(32)', and the server would behave as if the value had been explicitly pinned. #103991 (Groene AI).- Fix
SIZES_OF_ARRAYS_DONT_MATCHwhen readingAggregateFunction(topK(N), String)columns whose persistedalpha_sizewas grown by a pre-25.12 deserialize+serialize cycle. #104002 (Raúl Marín). - Fixed SQL injection vulnerability in PostgreSQL, Cassandra and XDBC dictionary sources: string keys containing single quotes were escaped with
\'(backslash), which these backends treat as a literal backslash rather than an escape sequence, allowing arbitrary SQL to be injected into dictionary lookup queries.ExternalQueryBuildernow emits SQL-standard''escaping for those backends; ClickHouse and MySQL dictionary sources continue to use backslash escaping. #104009 (Shaohua Wang). - Fixed possible type mismatch in aggregation when a column type was altered to/from LowCardinality, and min-max projection wasn't rebuilt. #104013 (Nikita Taranov).
- Fix infinite loop of query optimizations caused by not propagating prevention of unused column removal when merging expressions. #104083 (János Benjamin Antal).
- Fix
LOGICAL_ERRORinStreamingStorageRegistry::renameTablewhen batch-renaming streaming tables (S3Queue, Kafka, RabbitMQ) by using UUID-based identity tracking instead of name-based. #104101 (Nikita Taranov). - Fixed wrong results when a CTE constructed with
UNION ALLcontained aSELECT DISTINCTbranch and the outer query projected only a subset of the CTE's columns. The new analyzer'sRemoveUnusedProjectionColumnsPasswas incorrectly removing the un-referenced column from the innerDISTINCTprojection, causing rows that should have remained distinct (same value in the projected column but different value in the dropped column) to collapse into one. #104114 (Groene AI). - Fix several edge case correctness issues in setting
optimize_inverse_dictionary_lookupwhere the optimization could silently drop rows or suppress exceptions. Closes #103270. Close #103085. #104133 (Nihal Z. Miaji). - Fix write out of bounds while deserializing
quantileTimingstate. #104141 (Alexey Milovidov). - Fix undefined behavior when an out-of-range
Float64value is converted to a wide integer type (UInt64,Int64,Int128,UInt128,Int256,UInt256). Previously, values equal toFloat64(numeric_limits<T>::max())(which rounds up to a value above the actual maximum) bypassed the bounds check and produced UB in the subsequent cast. This affected aggregate-function parameter parsing (topK,histogram,uniqUpTo,groupArrayInsertAt, etc.) and integer-typed settings viaSET <setting> = <Float64>. Closes #103817. #104154 (Groene AI). - Fix
LOGICAL_ERRORexception "Unexpected return type from comparison. ExpectedUInt8. GotConst(Nullable(UInt8))" when comparing a nestedTuple(Tuple(Nullable(...)))(or deeper nesting) with aStringliteral. The comparison's return type is now correctly inferred asNullable(UInt8), matching the runtime behaviour. #104171 (Groene AI). - Fixed a server abort (
UndefinedBehaviorSanitizer: reference binding to null pointer, segfault in release builds) onSELECT ... FROM <ReplacingMergeTree(version, is_deleted)> FINAL PREWHERE is_deleted = <expr> AND <other column expr>whenquery_plan_optimize_lazy_final = 1. The lazy-FINAL non-intersecting reading step lost theis_deletedcolumn from its output header because prewhere consumed it as an input without re-exposing it as an output. The downstreamaddIsDeletedFilterstep then dereferenced a nullActionsDAG::Nodepointer. #104177 (Groene AI). - When calling system.failpoints table, it would use a failpoint, thus possibly disabling it. #104237 (Pedro Ferreira).
- Fix
MemorySanitizer: use-of-uninitialized-valueindetectLanguage*functions when the input contains a UTF-8 character ending exactly at the buffer boundary. #104257 (Raúl Marín). - Fix a logical error (
Bad cast from type DB::CachedObjectStorage to DB::S3ObjectStorage) that aborted argument parsing of data-lake table functions and engines (icebergS3,deltaLakeS3, etc.) when called withSETTINGS disk = '...'against a disk whose underlying object storage is wrapped by a decorator such as a filesystem cache. Closes #89300. #104258 (Groene AI). - Fix parsing of parenthesized subscript expressions on columns named
values, for example(values['a']), so they are no longer interpreted as SQL-standardVALUEStable expressions. #104312 (Desel72). - Fix a server abort/
LOGICAL_ERRORin the filesystem cache background eviction thread (SLRUFileCachePriority::collectEvictionInfo) that could fire whenkeep_free_space_size_ratioorkeep_free_space_elements_ratiowas high enough to trigger eviction while all cache entries had already been promoted to the SLRU protected queue (probationary empty). #104313 (Groene AI). - Fix exceptions (
NOT_FOUND_COLUMN_IN_BLOCK,LOGICAL_ERROR,AMBIGUOUS_COLUMN_NAME) when using projections with UNION ALL views, window functions, or alias-column name collisions. Regression from #88798. #104317 (Amos Bird). - Fixes a possible underflow in parsing postgres arrays. #104322 (Grant Holly).
- Functions that return a non-
Nullabletype (such asArray,Tuple, orMap) now acceptNullablearguments. Affected functions includeextractAll,extractAllGroups,extractAllGroupsHorizontal,extractAllGroupsVertical,extractGroups,splitByChar,splitByString,splitByRegexp,splitByWhitespace,splitByNonAlpha, andalphaTokens.NULLinput rows produce the default value of the result type (e.g. an empty array) instead of raising "Nested type is not allowed inside Nullable type". #104326 (Alexey Milovidov). - Fix iceberg stats with partitioned table. This closes #104321. #104329 (Konstantin Vedernikov).
- Fix a fatal logical error at server startup on macOS (and similar jemalloc builds) where
Jemalloc::verifySetupincorrectly reported ajemalloc_enable_background_threadsmismatch because optionalbackground_thread/max_background_threadsmallctls are absent; verification is skipped when those mallctls are unavailable, andgetValueno longer leaves the output uninitialized on failure. Closes #102183. #104330 (SAYON DEEP). - Fix a correctness regression where
SELECTqueries withmax_rows_to_read_leafandread_overflow_mode_leaf = 'throw'could incorrectly throwTOO_MANY_ROWSeven when a skip index would have reduced the read below the leaf cap. The symmetric non-leaf settings (max_rows_to_read/read_overflow_mode) were already handled. #104331 (Groene AI). toUUID,toUUIDOrNull,toUUIDOrZero,toUUIDOrDefault,CASTtoUUIDandNullable(UUID),accurateCastOrNulltoUUID, and the input formats that parse a UUID from text (Avro,MsgPack,JSONExtract, ...) now reject strings that have the right length but contain non-hexadecimal characters. Previously such inputs were silently turned into a fabricated UUID by walking off the end of the hex digit lookup table; nowtoUUIDthrowsCANNOT_PARSE_UUID, and theOr*variants returnNULL/ the zero UUID / the supplied default. #104370 (Groene AI).- Fix
Bad castLOGICAL_ERRORincaseWithExpression(and SQLCASE expr WHEN ... THEN ... ELSE ...) when the THEN-only supertype and the (THENs + ELSE) supertype land in differentColumnDecimalstorages -- for example THEN values(UInt16, Int8)with an ELSE ofDecimal(9, 2). Closes #104335. #104378 (Groene AI). - Internal failures reported via
logExceptionBeforeStart(asynchronous insert flushes, materialized-view refreshes, parse errors raised during internal queries) now correctly increment theFailedInternalQuery,FailedInternalSelectQuery, andFailedInternalInsertQueryProfileEvents alongside the user-visibleFailedQuery,FailedSelectQuery, andFailedInsertQuerycounters. Previously these internal counters stayed at zero for failures occurring before query execution started, undercounting a major class of internal failures. #104399 (Groene AI). - Fix
Code: 36. BAD_ARGUMENTS Expected literal, got {name:Type}thrown when a query parameter is used inside thebase_backupsetting of aBACKUPorRESTOREstatement (e.g.BACKUP ... SETTINGS base_backup = S3({backup_name:String}, ...)). The regression was introduced in26.1.5by PR #99205. Closes #103324. #104413 (Groene AI). - Fix a server abort in
IcebergLocal/IcebergS3writes whenALTER TABLE ... DROP COLUMNis followed by anINSERTwithiceberg_metadata_staleness_msgreater than zero.ALTERnow invalidates the local Iceberg metadata files cache so subsequent reads and writes see the new schema. #104419 (Groene AI). - Fix
DROP ROLE,DROP USER,DROP SETTINGS PROFILE,DROP ROW POLICY,DROP QUOTAandDROP MASKING POLICYto remove references to the dropped entity from any other access entity that referenced it (e.g. a user'sDEFAULT ROLElist, a settings profile'sTOlist, a row policy's grantees) and persist the cleanup to disk. Previously the in-memory state appeared correct becauseSHOW CREATEfilters unknown UUIDs, but the on-disk.sqlfiles retained danglingID('<dropped-uuid>')entries and the references were resurrected on the next server restart, surfacing asACCESS_ENTITY_NOT_FOUNDerrors during distributed query execution. #104427 (Groene AI). - Fixed a server abort triggered by
azureBlobStorage,AzureBlobStorage-engine, and DeltaLake-on-Azure with a connection string whoseBlobEndpointURL has an empty, non-numeric, or out-of-range port (e.g.BlobEndpoint=http://host:abc/). The server now returns a cleanBAD_ARGUMENTSerror instead of aborting in debug/sanitizer builds. #104460 (Groene AI). - Allow an unquoted identifier as the user name in the
remoteandremoteSecuretable functions, mirroring how the database and table arguments accept unquoted identifiers. Previously such a query failed with a misleading authentication error referring to thedefaultuser. #104465 (Alexey Milovidov). - Fixed
Logical error: Incorrect ASTSelectWithUnionQuery (modes: M, selects: N)triggered when a SQL user-defined function body contains a parenthesized innerUNION ALL(e.g.CREATE FUNCTION f AS x -> (SELECT 1 UNION ALL (SELECT 1 UNION ALL SELECT 1))). #104477 (Groene AI). - Fix
uniqThetaIntersectreturning the cardinality of the first argument instead of0when the second argument is an emptyuniqThetastate -- for example the result ofuniqThetaMergeStateIf(s, predicate)when the predicate excludes every row. #104529 (Groene AI). - Fix
SHOW TABLESandsystem.tablessilently truncating the listing forDataLakeCatalogdatabases backed by Iceberg REST catalogs (iceberg-rest,onelake,biglake). When the catalog server paginates the list-tables or list-namespaces response (e.g. Microsoft Fabric / OneLake beyond ~50 tables per namespace), tables on later pages were silently invisible toSHOW TABLESandsystem.tables, even though they were queryable via directSELECT.RestCatalognow follows thenext-page-tokencontinuation token defined by the Iceberg REST OpenAPI spec, matching the existing behavior ofPaimonRestCatalogandUnityCatalog. #104531 (Groene AI). - The
inputtable function now infers its structure from the surroundingINSERTquery'sFORMATclause when that format has a fixed schema (LineAsString,RawBLOB,JSONAsString, etc.), so users no longer have to repeat the structure asinput('line String')for these formats. #104532. #104533 (Groene AI). - Updated datatype of fields in Iceberg history from
Int32toInt64. Closes #94176. #104579 (Smita Kulkarni). - Fixed
Inconsistent AST formattingLOGICAL_ERRORwhen parsing a function call where a lambda follows a comma, e.g.SELECT substring(x, `x` -> `x`). The parser used to silently merge the preceding arguments into the lambda's left-hand side, producing a single-argument call that could not be re-parsed back to the same AST. It now preserves the function's original arity. #104626 (Groene AI). CHECK TABLE tnow prefers aTEMPORARYtable over a permanent one with the same name when no database qualifier is given, matching the precedence already used bySHOW CREATE TABLE,DESCRIBE TABLE,OPTIMIZE TABLE, andALTER TABLE. PreviouslyCHECK TABLE tskipped temporary tables entirely, so it failed withUNKNOWN_TABLEon a temporaryLogorFiletable even though those engines supportCHECK. Follow-up to #100966. #104637 (Groene AI).- Fix Keeper termination and restart loop when
get /keeper/availability_zoneis sent withquorum_reads=trueto a Keeper without<placement>configured. #104663 (myeongjun). - Fix a TOCTOU data race in
FutureSetFromTuple::buildOrderedSetInplacethat results in a logical error. #104673 (Miсhael Stetsyuk). - Fix several functions returning different results for the same input depending on whether arguments arrived as columns or constants:
bitRotateLeft/bitRotateRight(boundary shift counts),length(FixedString)/concatWithSeparatorwithLowCardinality(Nullable)inputs,roundDownon NaN, andrightUTF8on invalid UTF-8. #104710 (Raúl Marín). - Fixed
anyHeavyreturning a non-heavy value when the most frequent value was the column default and the data lived across multipleMergeTreeparts (sparse-column read path). #104712 (Raúl Marín). - Fix several defects in setting-constraint handling:
MergeTreeSettingsconstraints declared on a setting's canonical name could be bypassed by writing to an alias of that setting; thedisallowed_valuesconstraint check threw an exception on clamp paths (secondary queries,ON CLUSTERworkers,SQL SECURITY DEFINERviews) instead of silently dropping the change. #104737 (Raúl Marín). - Fix a
LOGICAL_ERRORexception (Metadata is not initialized) raised byOPTIMIZE TABLE,ALTER TABLE ... DELETE,ALTER TABLE ... ADD COLUMNand other ALTER variants on a lazily-attachedIceberg/IcebergLocal/DeltaLake/Huditable whose metadata had not been loaded yet (typical after a server restart, or after a previous metadata write failed and left a corrupted metadata file on disk). The operation now either proceeds normally if the metadata loads successfully, or surfaces the underlying load failure as a regular user-facing exception instead of aborting the server in debug / sanitizer builds. #104738 (Groene AI). - Fix segfault due to a use-after-free bug in
AvroConfluentRowInputFormat. #104751 (Miсhael Stetsyuk). - Scalar variants of
numericIndexedVectorPointwiseMultiply,numericIndexedVectorPointwiseDivide,numericIndexedVectorPointwiseEqual, andnumericIndexedVectorPointwiseNotEqualnow raiseINCORRECT_DATAwhen called with aUInt64scalar aboveInt64::max. #104784 (FriendLey). - Fix a bug where manually overriding a setting via its alias name (e.g.
SET enable_analyzer = 1instead ofSET allow_experimental_analyzer = 1) after applying acompatibilitysetting could cause that override to be reverted by a subsequent change of thecompatibilitysetting. #104829 (Raúl Marín). - Fix AWS logger being disabled after https://github.com/ClickHouse/ClickHouse/commit/0e8ad4355c9d. #104837 (Konstantin Bogdanov).
- Fix three more functions returning different results for the same input depending on whether arguments arrived as columns or constants:
transform(andcaseWithExpressionthrough it) with a constantDate/Date32/Enum/FixedStringdefault, comparison operators between aStringand a constantFixedString, andif/ifNull/nullIfwith aFixedStringbranch under a constant condition. #104858 (Raúl Marín). - Fix
Bad cast from type DB::ColumnConst to DB::ColumnNullableserver abort during partition pruning forMergeTreetables when the partition expression contains a function chain that collapses to a single constant value (such asfloor(NULL, toRelativeYearNum(...))). #104861 (Groene AI). - Fix a
ThreadSanitizerdata race in theContextDatacopy constructor:table_function_resultswas copied from the source object without acquiringtable_function_results_mutex, so a concurrentContext::executeTableFunctionwriter could race against the unsynchronized read in the copy constructor. #104879 (Groene AI). - Fix data part consistency checks for types with dynamic structure and detect corrupted columns_substreams.txt. Resubmit of https://github.com/ClickHouse/ClickHouse/pull/103858 with additional changes. #104888 (Pavel Kruglov).
- Fix race between DROP and UNDROP in DatabaseCatalog. #104915 (Azat Khuzhin).
- Fix filesystem cache dynamic resize with partially downloaded segments, including restore accounting after failed eviction. #104921 (Antonio Andelic).
DETACH TABLEon a temporary table (without theTEMPORARYkeyword) now correctly raisesSYNTAX_ERROR, matching the behavior ofDETACH TEMPORARY TABLE. Previously it silently set an internalis_detachedflag and returned without error. To remove a temporary table, useDROP TEMPORARY TABLEorDROP TABLE(the latter resolves the temporary table viaContext::ResolveExternal). Closes #103475. #104943 (Groene AI).- Make the
filesystemtable function honormax_memory_usage/max_server_memory_usagewhen loading file content. Previously, large or numerous parallel content reads could push past the limit without raisingMEMORY_LIMIT_EXCEEDEDand end up OOM-killed instead. #104956 (Alexey Milovidov). - Fixed a
LOGICAL_ERRORthrown when filteringsystem.detached_tablesbyuuid(e.g.SELECT count() FROM system.detached_tables WHERE uuid = '...'). The query now returns the expected result instead of aborting the server. #104979 (Groene AI). flattenTupleno longer raises aLOGICAL_ERRORwhen called on a tuple whose nested structure contains only emptyTuple()leaves (e.g.Tuple(c0 Array(Tuple()))orTuple(c0 Tuple())). Such inputs now produce a user-facingILLEGAL_TYPE_OF_ARGUMENTexception explaining that the flatten result would be an empty tuple. #104989 (Groene AI).- Fix a server abort and a silent-wrong-result bug when querying
loop(remote(...))(or anyloop()wrapping a storage that can defer aggregation) withGROUP BY. The outer planner used to addMergingAggregatedStepbased on the inner storage's reported processing stage, butLoopSourcealways materialises its inner select withQueryProcessingStage::Completeand emits plain column chunks, soMergingAggregatedTransformtripped aLOGICAL_ERROR(Chunk info was not set for chunk in MergingAggregatedTransform) underenable_parallel_replicas = 1and silently dropped the outer aggregation otherwise. #105001 (Groene AI). clickhouse-benchmark --reconnect(bare, no value) was inadvertently broken in 25.4 by a change that turned--reconnectinto an integer option, requiring a value. The bare form now works again and is equivalent to--reconnect=1(reconnect on every query). #105006 (Groene AI).- Fixed malformed JSON output for column names ending with incomplete UTF-8 sequences. #105012 (Pablo Marcos).
- Fix silent data loss after
EXCHANGE TABLESorCREATE OR REPLACE TABLEof a materialized view's source table. TheMV's source-view dependency edge is now kept on the original name so it continues to fire on inserts. Regression introduced by #98779; restores the pre-regression behavior. #105029 (Sema Checherinda). - Fix
CANNOT_COMPILE_CODE Could not find symbol __fixunsdftiwhen JIT-compiling expressions that convert aFloattoUInt128, such astoUInt128(<Float64 expression>). The unsigned 128-bit float-to-int compiler-rt builtins were missing from the JIT symbol resolver. Closes #105031. #105048 (Raúl Marín). - Fix
clickhouse-localnot printing log messages from a failed query whensend_logs_levelis set. #105067 (Alexey Milovidov). - Fix incorrect results when the same parameterized view is referenced more than once in the same query with different argument values. Previously, the analyzer collapsed the calls into one, silently dropping all but the first filter. #105170 (Alexey Milovidov).
- Fix
TOTALSrow being rendered twice at the bottom of the result table in theplay.htmlweb UI. #103803 (Alexey Milovidov). - Reject non-finite vectors (
NaN,±Inf) during vector search (either as searched vectors or as reference vectors); they previously caused undefined behavior inusearch. #104079 (Groene AI). - PromQL: fix the aggregation operator for empty vectors. #104425 (Vitaly Baranov).
- PromQL: fix error handling in the Prometheus query API. #104741 (Vitaly Baranov).
- Fix a race in
MergeTreeTransaction::afterCommitwhere, after a connection loss between writing the commitCSNto ZooKeeper and finalizing the transaction, theCOMMITresponse could reach the client before the newcreation_csn/removal_csnbecame visible insystem.parts. #104708 (Tuan Pham Anh). - Fix exponential memory growth in the KQL parser when converting nested array indexing (
arr[arr[arr[...]]]). #105142 (Alexey Milovidov). - Fix incorrect results for
RIGHT ANY JOINwhen the right table has multiple rows per key and the output block is split due to size limits. Closes #99431. #102064 (Vladimir Cherkasov). - Check for stack overflow in
Avroreader during nested-type deserialization. #102417 (Pavel Kruglov). - Fix duplicate rows in
system.completionsforMergeTreesettings — each setting name appeared twice because bothgetMergeTreeSettingsandgetReplicatedMergeTreeSettingswere dumped despite having identical setting names. Closes #102013. #102015 (Groene AI). - Fix
StorageObjectStorageQueue(S3Queue,AzureQueue) blocking shutdown until partially-processed files were fully read from object storage. The source now aborts the read immediately on shutdown; deduplication ensures rows already streamed into the destination table before shutdown are not duplicated when the file is retried on next start. #103126 (Tuan Pham Anh). - Fix multi-block inserts to the
Aliastable engine withinsert_deduplication_tokenso that all blocks are kept. #103246 (Enric Calabuig). - Fix
JSONHasandJSONExtractBoolon nativeJSONcolumns returning the extracted value (cast toUInt8) instead of0/1. #103313 (zxuhan7). - Protect the
CustomSeparatedinput format against malformed or adversarial data that omitsformat_custom_row_after_delimiter. Header detection, schema inference, and variable-column rows previously accumulated fields unboundedly and could allocate many gigabytes of memory before failing. Reads now fail withINCORRECT_DATAonce a single row contains more than 1,000,000 fields. #103404 (Groene AI). - Fix
RESTOREof replicatedMergeTreetables so that restored part attachment usesbackup_restore_keeper_max_retriesinstead of the regular insert Keeper retry budget. #104610 (Pablo Marcos). - Fix wrong results from
WHERE p AND <LowCardinality(Nullable(int)) constant>onMergeTreetables. Previously such queries returned zero rows because part pruning derived aNULLdefault from theLowCardinality(Nullable(...))type and synthesized anotEquals(x, NULL)guard, pruning every part. #104767 (Groene AI). - Fix incorrect aggregation result when grouping by a non-injective function of a column that is also the partition key (e.g.
PARTITION BY awithGROUP BY intDiv(a, 2)ora % 2). Values from different partitions that mapped to the same group were not merged, producing duplicate group rows underallow_aggregate_partitions_independently = 1. #104869 (Nihal Z. Miaji). - Fix a race in
Keepersnapshot transfer where a snapshot could be removed or moved while it was being sent to a recovering follower. #104941 (Antonio Andelic). - Fix a silent wrong-result bug in
hilbertEncodeandmortonEncodewhere a non-constantTuplefirst argument (range mask) used row 0's values to drive the bit-shift for every row. The functions now compute the per-row mask values, so the result no longer depends on the input being constant or on the block size. #104992 (Groene AI). - Fix
clickhouse-localsilently ignoring user-level configuration (profiles,users,quotas, access-control settings) when the configuration file is auto-discovered from./clickhouse-local.xml,~/.clickhouse-local/config.xml, or/etc/clickhouse-local/config.xml. Previously these settings were applied only when--config-filewas passed or./config.xmlexisted in the current directory; now all discovery paths behave consistently. #105008 (Groene AI). - Fix
BFloat16columns silently returning zero matches when compared against a string literal (e.g.WHERE bf16_col = '49.9'). #105042 (Raúl Marín). - Fix
CLEAR COLUMNand TTL handling during merges forSummingMergeTree,AggregatingMergeTree, andCoalescingMergeTreewhen merge-required columns are absent or expired. Closes #101953. #105203 (Antonio Andelic). - Fix a race between
DNSCacheUpdater::runandContext::reloadClusterConfigby adding an explicit null-guard forshared->clusters_configbefore dereferencing it. #105220 (Mikhail f. Shiryaev). - Fix
best_effortdate-time parsing fortoDateTime64withmsandnsprecision. #105233 (Kaviraj Kanagaraj). - Fix
OSIOWaitMicrosecondsreporting thread-lifetime I/O wait instead of per-query I/O wait. #105246 (Mikhail f. Shiryaev). Huditable engine now raisesINCORRECT_DATA(a regular query-level exception) instead ofLOGICAL_ERRORwhen a parquet file in the table directory does not match the Hudi[FileId]_[FileWriteToken]_[Timestamp].[extension]naming convention. Previously such file names caused an exception in debug builds. #105266 (Groene AI).- Fix deadlock in
ParallelFormattingOutputFormaton schedule failure: whenscheduleFormatterThreadForUnitWithNumberthrows (e.g.CANNOT_SCHEDULE_TASK), the unit was left inREADY_TO_FORMATwith no formatter thread to process it, leading to a hang. The schedule call is now wrapped intry/catchand any failure is routed throughonBackgroundExceptionso the collector exits cleanly. #105275 (Azat Khuzhin). - Fix silent data loss in
Distributedasync inserts when recovering from an abnormal shutdown: if the last.binfile in a saved batch was intact but a middle one was corrupted,DistributedAsyncInsertBatch::recoverBatchwould only validate the last file's header and thensendBatchwould mark the entire batch — including the intact files — as broken, losing their rows. Each file's header is now validated individually so only the actually broken file is moved tobroken/and the surviving rows reach the remote shard. #105281 (Groene AI). - Fix a regression in
clickhouse extract-from-config --try: when the config usedfrom_envattributes and had noinclude_fromelement (or had one pointing to a missing file), allfrom_envsubstitutions were silently dropped and returned empty strings. This broke the Docker entrypoint port discovery in 26.2.5. Closes #101704. #105283 (Groene AI). - Fix
INSERT INTOaSQLitetable failing with a SQLite syntax error when the inserted value is anEnum,JSON, orAggregateFunctionwhose text representation contains a single quote. Theoutput_format_values_escape_quote_with_quotesetting is now honored by the corresponding serializations (previously onlyStringandFixedStringhonored it). #105285 (Groene AI). - Fix
Code: 44. ILLEGAL_COLUMN: Cannot add column ...: column with this name already existsthrown by distributed queries withallow_push_predicate_ast_for_distributed_subqueries = 1(the default) when aGLOBAL INtuple is matched against a subquery whose projection contains duplicate column names, e.g.(x, y) GLOBAL IN (SELECT number, number FROM numbers(5)). #105290 (Groene AI). - Fix
reinterprettoArray(LowCardinality(...))returning a confusingNOT_IMPLEMENTEDerror at runtime; it now returnsILLEGAL_TYPE_OF_ARGUMENTduring type checking. #105301 (Raúl Marín). minMap/maxMap(array form) andminMappedArrays/maxMappedArraysnow treatNaNconsistently withORDER BY:NaNis treated as last (returned only when all values areNaN). Previously, results depended on the position ofNaNin the data due to IEEE 754 unordered comparison semantics, and disagreed with theMap-argument form ofminMap/maxMapthat was fixed in #100448. #105331 (Raúl Marín).- Fix a memory leak in the per-table
ColumnsDescriptioncache forMergeTree-family tables withNestedcolumns. Entries were never evicted acrossALTER ADD COLUMN/DROP COLUMNcycles whenshare_nested_offsets = 1(the default). #105376 (Groene AI). - Fix
BAD_ARGUMENTSexception "It's a bug! Only integer types are supported by__bitWrapperFunc" thrown when aSELECTwith aTYPE set(N)skip index has aWHEREatom whose result type isFloat,BFloat16, or any other non-integer type (for exampleWHERE c0 + 0.1orWHERE log(c0)). The skip index now falls back to the regular filter path in that case. #105384 (Groene AI).
Build/Testing/Packaging Improvement
- Stop using the system
compiler-rtlibraries and headers. Closes #91475. #102857 (Konstantin Bogdanov). - Refresh the distroless Docker base image to fix OpenSSL CVEs in
libssl3t64. #103583 (Rahul Nair). - Reliably receive the GPG key during releases by chaining multiple Ubuntu keyservers, instead of timing out on
keyserver.ubuntu.com. #103834 (Mikhail f. Shiryaev). - Remove and forbid build-time
CMakechecks (check_*,try_compile,try_run). The compiler and toolchain are fixed, so feature detection at configure time is unnecessary and is now blocked project-wide; any version-specific behaviour must be gated onCMAKE_CXX_COMPILER_VERSIONexplicitly. #103980 (Alexey Milovidov). - Bump
libarchivefrom 3.8.6 to 3.8.7. #104047 (Robert Schulze). - Update
mongo-c-driverto 2.3.0. #104300 (Raúl Marín). - Update LLVM dependencies for 22.x. #104381 (Joshua Carp).
- Make the embedded-client and PTY descriptor classes build on macOS and FreeBSD by using portable POSIX
posix_openpt/grantpt/unlockptand removing Linux-only#ifguards. #104436 (Alexey Milovidov). - Upgrade
librdkafkato version 2.14.1. #105222 (János Benjamin Antal).
ClickHouse release 26.4, 2026-04-30. Presentation, Video
Backward Incompatible Change
- The
INoperator now uses exact value semantics forBooltype: only0and1values in the set matchBoolvalues. Previously, numeric values greater than255in theINset were incorrectly clamped to true when compared againstBool, soSELECT CAST(1, 'Bool') IN (256)returned 1. Now it correctly returns0. Closes #92980. #93115 (Ashrith Bandla). - The H3 library has been updated to v4, which improves the precision of length, area, and other metric calculations. This change is backward incompatible because the new results differ from previous ones. #100348 (Alexey Milovidov).
- Disallows using
SELECTas a bareword identifier in aWITHexpression list element. #101059 (Aruj Bansal). - This patch changes how the merge table will handle virtuals. If the underlying table contains
_tableor_database, these columns will be read from storage; otherwise, they will be filled after the read step using the expression step. #101742 (Mikhail Artemenko). - The
INoperator now rejects lossyDecimalconversions inside composite types (Tuple,Array,Map) as well, making its behavior consistent with top-level scalar comparisons. Previously, precision checks were enforced only for top-level scalar values: for example,CAST('33.3', 'Decimal64(1)') IN (33.33)correctly returned0, butCAST(['33.3'], 'Array(Decimal64(1))') IN ([33.33])incorrectly returned1because the lossy conversion happened inside anArray. Now both cases correctly return0. #101812 (Nihal Z. Miaji). - Reduced default
http_max_fieldsfrom 1,000,000 to 1,000 andhttp_max_field_name_sizefrom 128 KB to 4 KB to limit pre-authentication memory usage by HTTP connections. Addedhttp_max_request_header_sizeandhttp_headers_read_timeoutsettings. Users who rely on the previous higher limits can restore them via settings. #103285 (Sema Checherinda).
New Feature
- Add automatic spilling to hash and parallel hash joins by converting them to grace hash join when memory limit is reached. This behavior is controlled by
max_bytes_before_external_join. #97813 (János Benjamin Antal). - Add Arrow Flight SQL support. #91170 (Yakov Olkhovskiy).
- Add incremental read support for
Paimontable engines with Keeper-backed snapshot progress tracking, including targeted snapshot delta reads viapaimon_target_snapshot_id, and extend test coverage for type mapping, partition pruning, and incremental read scenarios. #93655 (XiaoBinMu). - The
stemfunction is now non-experimental (previously, settingallow_experimental_nlp_functionshad to be enabled). #102399 (Jimmy Aguilar Mena). You can now stem all the words/tokens in columnsString,FixedString,Array([Fixed]String),Nullable,LowCardinalityandConsteasily with thestemfunction. #99137 (Jimmy Aguilar Mena). - Implement new behavior of
max_insert_block_size_rows,max_insert_block_size_bytes,min_insert_block_size_rows,min_insert_block_size_bytesin squashing under compatibility settinguse_strict_insert_block_limits. #94207 (Kirill Kopnev). - Add function
arrayAutocorrelation(arr [, max_lag])that computes the normalized autocorrelation of a numeric array for each lag. Supports integer, float, and decimal array types. #94776 (Wenyu Chen). - A SQL function
obfuscateQuery. Closes #98010. #98305 (Xuewei Wang). - Add support for Map and JSON/Object types as dictionary attributes. Now dictionaries can store and retrieve complex types including Map(String, String), Map(String, Array(String)), JSON, and Nullable(JSON) types in both FLAT and HASHED layouts. #98627 (yanglongwei).
- Added two new MergeTree settings —
replicated_fetches_min_part_levelandreplicated_fetches_min_part_level_timeout_seconds— that allow replicas to skip fetching freshly-inserted (unmerged) parts from peers, reducing replication overhead during heavy ingestion. #98625 (tanner-bruce). - Add MergeTree skip index support for JSON columns using JSONAllPaths with bloom_filter, tokenbf_v1, ngrambf_v1, and text (inverted) index types, enabling granule skipping based on the set of JSON paths present in each granule. #98886 (Pavel Kruglov).
- The
printffunction now supports non-constant format strings, allowing different format patterns per row based on column values. #98991 (Yash ). - Add a new projection index,
commit_order, that reorganizes data in insertion order. #99004 (Mikhail Artemenko). - Add
highlightfunction that wraps occurrences of search terms in a text string with HTML tags (default<em>/</em>). Supports ASCII case-insensitive matching, automatic merging of overlapping matches, and custom open/close tags. #99131 (Peng). - Implement quotas by normalized query hash to protect public ClickHouse services from abuse. 1. Support
NORMALIZED_QUERY_HASHas a quota key type - separate quota buckets per unique normalized query, soCREATE QUOTA q KEYED BY normalized_query_hashtracks each distinct query independently. 2. SupportQUERIES_PER_NORMALIZED_HASHas a quota resource type -- limits max executions of any single normalized query within an interval, soMAX queries_per_normalized_hash = 100prevents any one query pattern from running more than 100 times. #99586 (Alexey Milovidov). - Users can now write join queries using the
NATURAL JOINsyntax, which automatically matches on all columns sharing the same name and deduplicates those columns in the result. #99840 (Peter Nguyen). - Support
SET TIME ZONE 'tz'as alias forSET session_timezone. #99883 (phulv94). - Added support for parameterized queries in the Web UI (
play.html): query parameters like{name:Type}are detected and input fields are shown for filling in their values. #100041 (Alexey Milovidov). - Support SQL standard
VALUESclause as a table expression inFROM, e.g.SELECT * FROM (VALUES (1, 'a'), (2, 'b')) AS t(id, val). #100143 (Desel72). - Add PostgreSQL-compatible units to the
EXTRACToperator:EPOCH,DOW,DOY,ISODOW,ISOYEAR,WEEK,CENTURY,DECADE,MILLENNIUM. Also fixEXTRACT(WEEK FROM date)which previously threw an error. #100274 (Alexey Milovidov). - Added support for SQL-standard compound interval literals with
TOrange qualifiers, e.g.INTERVAL '1:30' HOUR TO MINUTE. Internally decomposed into sums of intervals. #100453 (Desel72). - Add asynchronous metrics for kernel TCP receive and transmit buffer memory (
sk_rmem_alloc,sk_wmem_alloc) of HTTP connection pool sockets, reported as p50/p75/p90/p95 percentiles and totals per connection group. #100575 (Sema Checherinda). - Added a jemalloc profiling web UI for ClickHouse Keeper, available at
/jemallocon the HTTP control port. #100606 (murphy-4o). - Implement command
SYSTEM FLUSH OBJECT STORAGE QUEUE db.table PATH 'x'for ordered and unordered modes. #100709 (Bharat Nallan). - Added function
JSONAllValuesthat returns all values from aJSONcolumn asArray(String), with values serialized in text representation and ordered by their path names. Added support of text index forJSONAllValuesexpression onJSONcolumns. When a text index is created onJSONAllValues(json_column), it is automatically used to filter queries onJSONsubcolumns (e.g.,json_column.key1 = 'value'). #100730 (Anton Popov). - Adds a new setting
input_format_column_name_matching_modewhich allows different case sensitivities for input formats. #99346 (manerone). - Add
watchcommand toclickhouse-keeper-clientwith watch support inget,exists, andlscommands. #100834 (Den Kalantaevskii). - Added
getChildrenRecursive(ListRecursive) request to ClickHouse Keeper andlsrcommand toclickhouse-keeper-client. This closes #99916. #100998 (Konstantin Vedernikov). - Add new function
arrayTransposetaking a two-dimensional array (matrix) and transposing it:SELECT arrayTranspose([[1, 2, 3], [4, 5, 6]]). #101214 (Vitaly Baranov). auto_statistics_types mergetreesetting defaults to'minmax, uniq'— minmax and uniq statistics are created automatically for all suitable columns in new tables -materialize_statistics_on_insertdefaults to false — statistics are now built during merges rather than at insert time, reducing insert overhead. useSET materialize_statistics_on_insert = 1to restore the old behavior. #101275 (Han Fei).- Add
prefer_dependency_replicarefresh setting for materialized view dependency chains to reduce missing data from cross-replica replication lag. #101591 (Seva Potapov). - Adds a
hasPhrase(aliasmatchPhrase) function for phrase search (continuous sequences of tokens). Search is brute-force, i.e. not supported by the text index yet. #101997 (Elmi Ahmadov). - Add
s3_read_request_duration_microsecondsands3_read_request_byteshistogram metrics to observe S3 GET request connection lifetime and bytes consumed, visible insystem.histogram_metricsand the Prometheus endpoint. #102058 (Sema Checherinda). DateandDate32values can now be added toTimeandTime64values using the+operator, producing aDateTimeorDateTime64result. For example,SELECT toDate('2024-01-15') + toTime('14:30:25')returns2024-01-15 14:30:25. The result is computed in the session timezone, and out-of-range results are handled according to thedate_time_overflow_behaviorsetting. Closes #95914. #102421 (Nihal Z. Miaji).- The text index is now GA and stays enabled regardless of the
compatibilitysetting, preventing unexpected disabling during backup restores or when running in compatibility mode. #101518 (Nikita Fomichev).
Experimental Feature
- Add
ALTER TABLE ... EXECUTE remove_orphan_filesfor Iceberg tables to identify and remove unreferenced files from object storage. #99127 (murphy-4o). - Add
query_plan_optimize_join_order_randomizesetting that randomizes statistics used for join reordering, useful for testing. #100643 (Vladimir Cherkasov). - Add AI function support to ClickHouse, allowing users to call OpenAI and Anthropic endpoints using SQL.
aiGenerateis included as the first such function. #100831 (George Larionov). - Add AI functions:
aiClassify,aiExtract, andaiTranslatefor utilizing LLM APIs in ClickHouse. #100832 (George Larionov). - Added
system.histogram_metric_log, a new system table that periodically snapshots all histogram metrics (e.g. S3/Azure latencies, keeper request processing stages durations). Also, thevaluecolumn ofsystem.histogram_metricschanges toFloat64as it's more flexible and compatible with the Prometheus data model. #103046 (Miсhael Stetsyuk). The table structure is likely to be changed in future releases.
Performance Improvement
- ClickHouse is now able to prune entire data parts in SELECT queries based on min/max statistics. #94140 (zoomxi).
- Reduce lock contention during readonly operations on ReplicatedMergeTree tables with finished mutations. #95771 (Eduard Karacharov).
- Respect
optimize_read_in_orderwhen reading projections. Closes #89453. #95885 (Andrey Zvonov). - Small set of improvements in Hash Join and Concurrent Hash Join. #96663 (Yarik Briukhovetskyi).
- Optimize
DISTINCTtransform by disablingLowCardinalitycolumns optimization when input data is almost distinct. #97113 (Nihal Z. Miaji). - Performance optimization for
LIKEqueries from #97723. Now these queries can use text indices. #98149 (Elmi Ahmadov). - Vectorized math functions (
exp,log,sigmoid,tanh) are now accelerated on AArch64 (using NEON/SVE) and on FreeBSD/Darwin, where they previously used a slower scalar fallback. #98230 (Raúl Marín). - Queries filtering on
MergeTreeprimary key columns with regexp alternations over literal strings, such as^(abc-1|abc-2), can now use primary key pruning when the alternatives share a common prefix. #98988 (Yash ). - Generalize
ORDER BY ... LIMITtop-k dynamic filtering to supportNullable,String, andCOLLATEtypes. #99033 (murphy-4o). - Speedup hash join on
Int32andInt64keys with small range by using a direct-index hash table. #99275 (Hechem Selmi). - Faster discontinuous queries for
LowCardinalitycolumns with a single dictionary. #99285 (Ivan Babrou). - Speed up
var*Stableandstddev*Stablefunctions forFloat64columns by devirtualizing the inner loop. Note: this enables compiler optimizations (FMA/registers) that alter floating-point results at the ULP level. #99460 (Riyane El Qoqui). - Use optimised Firedancer base58 encode for inputs of 32/64 bytes (automatic for
base58Encode). Allow using optimised base58 decode if decoded result is 32/64 bytes (explicit withbase58Decode('...', 32)or alike). #99461 (Joanna Hulboj). - Enable linker section-based optimizations (
-ffunction-sections,-fdata-sections,--icf=all) to reduce binary size and improve instruction cache utilization. #99474 (Alexey Milovidov). - Fix negative scaling for short queries with aggregation on machines with many cores. When a query reads few marks, the pipeline no longer expands to
max_threadsafter aggregation, avoiding overhead from mostly-empty streams. #99493 (Alexey Milovidov). - Improve the performance of queries with parallel replicas by correctly selecting the reading task size. #99801 (Nikita Taranov).
- Allow prefetching when reading a remote file through the userspace page cache. #99919 (Alexey Milovidov).
- Avoid unnecessary computation of String
.sizesubcolumn during subcolumns enumeration. #99941 (Pavel Kruglov). - Make clickhouse-client's progress bar less jittery when working from a hotel with clusters with a very large number of replicas. #100145 (Alexey Milovidov).
- Start
MemoryWorkerinclickhouse-localwhen page cache is enabled, so that the userspace page cache can be actually used. #100306 (Alexey Milovidov). - Optimize queries by pushing the
LIMITclause down into theUNION ALL. #100364 (Alexey Milovidov). - Add JIT compilation support for
StringandFixedStringcolumn comparisons inORDER BY, improving merge-phase sort performance by 6–17% for string-heavy sort keys. Co-authored with @lgbo-ustc. #100577 (Raúl Marín). - When
read_in_order_use_virtual_rowis enabled together with the newread_in_order_use_virtual_row_per_blocksetting, virtual row boundary information is now emitted after each block read fromMergeTree, allowing the merge to reprioritize sources mid-stream for parts whose data is fully filtered out byWHERE/PREWHERE/JOIN. Close #99945. #100603 (Vladimir Cherkasov). - Faster Float-to-String conversion for large integer values by extending the
itoafast path with dragonbox-compatible rounding. #100649 (Raúl Marín). - Replace
dragonboxwithzmijfor 1.5x-3x faster Float-to-String conversion. #100650 (Raúl Marín). - Faster
Int128/UInt128to string conversion by replacing software division with Barrett reduction and unrolling the conversion loop. #100671 (Raúl Marín). - Avoid spawning redundant threads in
uniqExactparallel merge. #100686 (Jiebin Sun). - Add batch parallel merge for
uniqExact. #100687 (Jiebin Sun). - Better parallelization of queries with simple views (with underlying
MergeTreetable) executed with parallel replicas. #100815 (Igor Nikonov). - Implements support of parallel replicas over simple views (including eligible
UNION ALLviews overMergeTreetables) whenparallel_replicas_allow_view_over_mergetree=1. This allows to parallelize view's outer query instead of inner one which increases query parallelization across nodes. #100958 (Igor Nikonov). - Optimise reading in order of the primary key for
full_sorting_mergewhen filters withINare present in the query plan. #101261 (Nikita Taranov). - Optimization allocations/deallocations by caching sampling settings instead of traverse all memory tracker hierarchy. #101267 (Azat Khuzhin).
- Fix significant INSERT performance regression when
deduplicate_insert = 'enable'(default since 26.2) by deferring data hash computation from squashing to the sink and using batch column hashing viaupdateHashWithValueRange, reducing overhead from ~2.5s to ~0.5s for 5M rows with 22 columns. #101494 (Sema Checherinda). - Reduce profiled lock overhead by using
try_lockto avoid timing uncontended acquisitions and removing hold-time measurement. #101502 (Antonio Andelic). - Replace hand-written AVX-512 intrinsics in
arrayDotProductwith platform-independent auto-vectorizable loops, adding AVX2 and ARM NEON support. #101571 (Peng). - Improve performance in
INSERT VALUESforMap,Array, andTuplecolumns when values are passed as escaped strings (e.g.'{\'key\':1}'), avoiding unnecessary fallback to the SQL expression parser. #102119 (Joanna Hulboj). - Fixed excessive
RabbitMQtable engine CPU usage. #102711 (Jaap Elst). - The JOIN order optimizer now infers transitive equi-join predicates from existing join conditions. For example, given
A.x = B.x AND B.x = C.x, the equivalenceA.x = C.xis recognized, allowing the optimizer to consider direct joins between transitively-connected tables. This can improve plan quality for star and snowflake schemas where dimension tables connect through a shared fact table. The feature is controlled by the newenable_join_transitive_predicatessetting (off by default). #98479 (Alexander Gololobov). - Optimize
TRUNCATE DATABASE TABLES LIKEby pre-cancelling merges in parallel. #98597 (Shaohua Wang). - Add monotonicity support for multiply, enabling primary key pruning for
key * constantexpressions. #98983 (Amos Bird). - Cache dictionaries no longer take an exclusive lock in
hasKeys; this reduces lock contention by using a shared lock for cache reads. #100796 (liuguangliang). - Inline VIEW subquery in the query tree to allow more optimisations to be applied to the VIEW. #100830 (Dmitry Novik).
- Optimize cache loading on server startup. #101500 (Kseniia Sumarokova).
- Implement lazy column materialization for ReplacingMergeTree with FINAL in case the predicate is selective enough. #101647 (Nikolai Kochetov).
- Re-enable the
optimize_rewrite_array_exists_to_hasoptimization (off by default since 23.10). It rewritesarrayExists(x -> x = elem, arr)into the much fasterhas(arr, elem)and now correctly skips the rewrite when the array element type andelemare not compatible forhas(e.g.DatevsString), so previously breaking queries continue to work. Closes #71431. #100944 (Alexey Milovidov).
Improvement
- Improved EXPLAIN PLAN pretty=1 output: print top-level query output columns, show join relation labels/symbols with estimated result rows and locality, and include per-step output columns for join/source steps. The changes cover Information Deficit part from #98117. #99462 (Kirill Kopnev).
- Add MergeTree table setting
share_nested_offsets(defaulttrue). When set tofalse, Array columns with dotted names (e.g.n.a,n.b) are treated as independent columns instead of sharing offset files and validating equal array sizes as part of legacyNestedsemantics. #98416 (Amos Bird). - Users can now specify multiple authentication methods in users.xml/yaml configuration (in SQL it was always possible). #91998 (Flip-Liquid).
- Auto reload Raft inter-node connections which are using TLS. #93455 (Evgeny).
- Extend
cast_keep_nullableto work with Dynamic/JSON types. When set, casting NULL from types that can be Nullable will return NULL, otherwise NULL will throwCANNOT_INSERT_NULL_IN_ORDINARY_COLUMNerror. #96504 (Seva Potapov). - Reduced the memory footprint from the internal data structures (
ISerializationobjects) by introducing an object pool. #96563 (Nikita Mikhaylov). - Add support of
passwordandidentityfields to keeper-client XML config. #96800 (Grigorii Sokolik). - Improve
Icebergwrites for the unity catalog. #98162 (Konstantin Vedernikov). - Add setting
finalize_projection_parts_synchronouslyto allow synchronous finalization of projection parts during INSERT, reducing peak memory usage for tables with many projections while preserving existing async behavior by default. #98228 (Amos Bird). - Add
projections_duration_mscolumn tosystem.part_logthat records per-projection merge/rebuild duration in milliseconds. #98292 (Amos Bird). - Improve canceling queries using ExpressionTransform and NumbersRangedSource by KILL QUERY and cancel query (Ctrl+C) in clickhouse-client. #98908 (Roman Vasin).
- Replace the hardcoded
source_table_engineslist with a runtime lookup viaStorageFactory::getAllStorages(). This adds access checks for some missing table engines and closes #71544. #98984 (pufit). - Add a setting to control type mismatch behavior for Variant and Dynamic (throw or return null). #99085 (Bharat Nallan).
- Improve
Icebergand Spark compatibility: fix inconsistent path handling caused by mixed usage of storage paths and metadata paths; enforce thatIcebergtables write down a table location that is either a URL or an absolute path; add a fallback for counting file sizes inAzurebecause some ClickHouse readers don't support byte counting after traversal; handleversion-hint.txtin a manner compatible with Spark; introduce type-level abstractions that make it harder to mix up path types in the future; add tests forAzureandLocalthat verify cross-engine interoperability without intermediate uploading/downloading; fix usage of position deletes, which previously relied on path inference heuristics where that approach is inappropriate. #99163 (Daniil Ivanik). #100420 (Daniil Ivanik). - Fix possible race condition in
IPartitionStrategy::cached_resultintroduced in https://github.com/ClickHouse/ClickHouse/pull/92844. #99400 (Arthur Passos). - Users can now write ClickHouse Interval datatypes in the Arrow Format. #99519 (Peter Nguyen).
- Adds native support for importing and exporting
UUIDdata types inArrowandParquetformats. Users can now directly query and transfer UUID data between ClickHouse and other data tools without requiring manual string conversions or workarounds. Automated logical inference for top-level UUIDs, and support for explicit schema hint for nested UUIDs. #99521 (Ivan). - Support
7zarchives on object storage. Closes #70968. #99600 (Alexey Milovidov). - Add
ObjectStorageListedObjects,ObjectStorageGlobFilteredObjects,ObjectStoragePredicateFilteredObjects, andObjectStorageReadObjectsProfileEvents for introspection of object storage (S3,Azure, etc.) file listing and reading pipeline. #99778 (Sema Checherinda). - Fix
mergetable function failing withUNKNOWN_IDENTIFIERerror when querying columns not present in all underlying distributed/remote tables. #99833 (Alexey Milovidov). - Now we include commit time in total mutation execution time metric for ReplicatedMergeTree. It was lost after #96376. #99936 (alesapin).
- Add a write-ahead log for blob objects pending removal in
MetadataStorageFromDisk, improving durability and consistency between metadata and remote object storage when objects are deleted. #100019 (Maksim Kita). - Disable AI SQL generation (
??command) in the embedded client (SSH and WebSocket protocols) to prevent access to the server's environment variables. #100290 (Alexey Milovidov). - Change the interface for Iceberg inserts with the catalog. Deprecate settings:
storage_catalog_type,storage_aws_access_key_id, etc. #100334 (Konstantin Vedernikov). - Render tabs as 4 spaces when pasting into clickhouse-client. Closes #100405. #100416 (Raúl Marín).
- Avoid scanning the whole remote data lake catalog for “Maybe you meant …” table hints when
show_data_lake_catalogs_in_system_tablesis disabled. #100452 (Alsu Giliazova). - Apply
distributed_index_analysis_min_indexes_bytes_to_activateafter partition pruning. #100477 (Azat Khuzhin). - Fix assertion failure in Parquet bloom filter push down when using empty IN/NOT IN clauses. #100543 (zoomxi).
- MinMax column statistics now store the minimum and maximum values as Field (typed) instead of Float64. The serialized format includes the column type name alongside the values. The statistics file version is bumped to V2; files written by older versions require re-materialization (ALTER TABLE … MATERIALIZE STATISTICS ALL). fix #53140. #100605 (Han Fei).
- Update
cppkafkato include fix for Consumer close deadlock. #100612 (Azat Khuzhin). - Object information used for parsing data files in Iceberg now contains the number of file rows and file size in bytes parsed from manifest file. #100645 (Daniil Ivanik).
- Add
use_separate_cache_arenaconfiguration parameter to be able to control separation of the cache memory arena. #100664 (Seva Potapov). - Adds native support for importing Apache Arrow's
StringViewandBinaryViewdata types into ClickHouseStringcolumns, improving compatibility for Arrow-based ingestion. #100762 (Ivan). - A few Keeper server settings are now hot-reloaded if config file is changed at runtime: max_requests_batch_size, max_requests_batch_bytes_size, max_request_size, quorum_reads. #100773 (Michael Kolupaev).
- Increment profile events
MemoryAllocatedWithoutCheck/MemoryAllocatedWithoutCheckBytesin release build. #100899 (Pavel Kruglov). - Cgroupv2 memory tracking now excludes
slab_reclaimablefrom kernel memory, giving a more accurate measure of non-reclaimable memory usage. #100901 (Antonio Andelic). use_partition_pruning = 0now also disablesMinMaxindex pruning and count optimization on partition key columns, in addition to disabling pruning based on partition keys. #100904 (Nihal Z. Miaji).pretty=1inEXPLAIN [PLAN]now prints expressions in a human readable format. #100927 (Kirill Kopnev).accurateCastOrNullandaccurateCastOrDefaultnow supportTupletarget types, including nestedTupleswithNullableelements. Previously these functions rejectedTupletargets becauseTuplecould not be insideNullable. Closes #100820. #100942 (Nihal Z. Miaji).- Fix chart duplication in Play UI when switching between light and dark themes. #101058 (Alexey Milovidov).
- Update chdig to v26.3.1 (perfetto UI, sparklines to summary for CPU/Memory/Merges/Queries), system.warnings, regexp search in logs). #101092 (Azat Khuzhin). Update chdig to v26.4.3 (perfetto improvements, fixes for sharing via pastila.nl, flamegraph diffs, change settings in realtime). #103145 (Azat Khuzhin).
- You can now have a trailing comma in the
WITHclause before aSELECTquery. #101093 (Aruj Bansal). - Add
compress_per_column_in_compact_partsMergeTree setting to control how compressed blocks are organized within Compact parts. Whentrue(default, preserving current behavior), each column starts a new compressed block, allowing selective decompression. Whenfalse, all columns within a granule are packed into the same compressed block, improving compression ratio and read performance for workloads that always read all columns. #101114 (Amos Bird). - Show table info balloon in Play UI only when hovering over the table name, not the entire row. #101118 (Alexey Milovidov).
- Add engine-specific icons and improve table list UX in the Play UI sidebar. #101134 (Alexey Milovidov).
- Support
Nullable(Tuple)forArrow,ArrowStream,ORC, legacyParquetformats. #101272 (Nihal Z. Miaji). - Display TOTALS row as a table footer in the web UI (play.html). #101286 (Alexey Milovidov).
- Support multi-query mode in the web UI (
play.html): run multiple queries at once with parallel execution ofSELECT-like queries and per-query result display. #101290 (Alexey Milovidov). - Fix column resize in play.html web UI after the result table was refactored into a web component. #101295 (Alexey Milovidov).
- Add ability limit amount of jemalloc profile flushes on MEMORY_LIMIT_EXCEEDED per time interval. #101396 (Azat Khuzhin).
- Added keeper settings
nuraft_streaming_mode(by defaultfalse),nuraft_max_log_gap_in_stream,nuraft_max_bytes_in_flight_in_stream. Closes #90743. #101427 (Kseniia Sumarokova). - Added
CGroupMemoryUsedWithoutPageCacheasync metric that reports cgroup memory usage excluding both the kernel OS page cache and the ClickHouse userspace page cache, mirroringMemoryResidentWithoutPageCache. Also clarified theCGroupMemoryUsedmetric description. #101513 (Francesco Ciocchetti). - Add parser-level syntactic sugar for the SQL standard
OVERLAYfunction syntax. Theoverlayfunction already exists; this adds support for the keyword-based form usingPLACING,FROM, andFORas separators. #101681 (Desel72). - Added column alias
INDEX_LENGTHto system tableinformation_schema.tables, analogous to existing uppercase aliases in this table. #101705 (Robert Schulze). - System table
information_schema.tablesnow ignores inactive table parts. This makes the shown table size values more realistic. #101706 (Robert Schulze). - The
ngramsfunction now rejects invalid ngram lengths. Example:SELECT ngrams('abc', 0)now returns an error. #101922 (Robert Schulze). - A follow-up for #91820 and #90837: filter unsupported algorithms from the error message; run FIPS-specific tests in FIPS builds. #102067 (Mikhail f. Shiryaev).
- Limit cell height to three lines in the Web UI (
play.html), with expandable cells on click. #102154 (Alexey Milovidov). - Added new option that allows to force (virtual/path) style for S3 endpoints. Resolves #82019; #76007 Continue of https://github.com/ClickHouse/ClickHouse/pull/83168. #102378 (Konstantin Vedernikov).
- The
restore_replace_external_engines_to_nullsetting now also skips restoring databases with external engines (e.g.DataLakeCatalog,MySQL,PostgreSQL,S3) instead of failing or initiating external connections. #102400 (Nikita Fomichev). - Add text index analysis support for the
hasPhrasefunction via theHINTmode. #102438 (Elmi Ahmadov). - Treat STATISTICS as read-only in ColumnDependency to fix LOGICAL_ERROR during MATERIALIZE STATISTICS ALL. #102627 (Konstantin Bogdanov).
- Create and populate
system.asynchronous_metric_login keeper-as-server mode. #102664 (Miсhael Stetsyuk). - Add
default_system_log_flush_policy.skip_alias_columnsconfig option to allow omitting ALIAS columns from system log tables, fixing S3-backed system logs that reject ALIAS columns. #102669 (Miсhael Stetsyuk). - Don't enable auto statistics for system tables. They rarely have chance to use them. #102862 (Han Fei).
- Support
arraytokenizer for the LIKE optimization. #102880 (Elmi Ahmadov). - Send MemoryAllocatedWithoutCheck even in release builds. #103064 (Azat Khuzhin).
- Expose per-thread untracked_memory in system.stack_trace. #103065 (Azat Khuzhin).
Bug Fix (user-visible misbehavior in an official stable release)
- Fix
Block structure mismatch in streamerror caused by unnecessary columns returned from Lazy materialization. Fixes #95191. #96682 (Nikolai Kochetov). - Fix a logical error with data masking policy query with
ON CLUSTER. #97594 (Bharat Nallan). - Fix a bug when using Unity catalog on top of GCS. #98456 (Melvyn Peignon).
DataLakeCatalognow respects the server'shttp_forbid_headersconfiguration when validating theauth_headersetting. #98827 (Michael Anastasakis).- Fix N+1
HeadObjectcalls for S3 brace-expansion globs. #99219 (Konstantin Bogdanov). - Validate setting changes in create queries when the engine itself also supports settings. #99279 (János Benjamin Antal).
- Fixed
ALTER TABLE UPDATE/DELETEfailing withMissing columnserror when a table has a MATERIALIZED column whose expression depends on an EPHEMERAL column. #99281 (Yash ). - Credentials in JDBC, ODBC, and NATS connection strings are now masked in query logs and
SHOW CREATEoutput, preventing accidental exposure of sensitive information. For URI-style connection strings (e.g.{scheme}://{user}:{password}@{host}), only the password portion is masked while the rest remains visible for easier debugging. Thenats_tokensetting is now also masked. #99344 (János Benjamin Antal). - Fix parseDateTimeBestEffort incorrectly parsing words starting with month prefixes in DD-month-YYYY format. Closes #99345. #99350 (Pavel Kruglov).
- Fix ignoring of TABLE_UUID_MISMATCH for non analyzer. #99380 (Azat Khuzhin).
- Fix a bug where explicit settings sent alongside
compatibilityin the same request could be silently ignored when their value matched the server default. #99402 (Raufs Dunamalijevs). - Fixes cases where numbers with leading zeros in hive partitioning path were causing errors. Fixes #98801. #99458 (Yarik Briukhovetskyi).
- Fix heap-use-after-free when a table is dropped concurrently with a running read query (19 occurrences in CI over the last 90 days). #99483 (Alexey Milovidov).
- Fixed a bug in Keeper where a read request could get stuck (causing session to time out) if a different unrelated session on the same server was closed at just the wrong moment. #99484 (Michael Kolupaev).
- Validate column structure before applying patches. #99531 (Seva Potapov).
- Fix vertical merge
rows_sourcesassertion failure whenSYSTEM STOP/START MERGEStoggles rapidly during merge of table withDynamiccolumns. #99532 (Alexey Milovidov). - Fix incorrect partition pruning for
toWeek()that caused queries withWHERE toWeek(date, mode) = Nto return empty results for weeks 49-52 on tables partitioned bytoYYYYMM(date). #99542 (Takumi Hara). - Fix exception in functions operating on ColumnReplicated with unreferenced rows produced by JOIN. #99564 (Hechem Selmi).
- Fix
CLEAR COLUMNnot rebuilding projections and not reevaluation materialized columns that depend on the cleared column, which could cause exceptions or data corruption during subsequent merges. #99565 (Desel72). - Fixed an exception (
Bad get: has Tuple, actual type String) inConditionSelectivityEstimatorwhen a query uses IN with a single scalar query parameter (e.g.WHERE col IN ({p:String})) on a table that has column statistics anduse_statisticsis enabled. #99614 (Ilya Yatsishin). - Part with unknown projections should not be marked as lost forever. #99623 (Sema Checherinda).
- Fix a rare logical error exception during vertical merge when
SYSTEM STOP MERGESandSYSTEM START MERGESare executed concurrently. #99628 (Desel72). - Fix dangling reference in injectRequiredColumns causing crash during merge. #99679 (Tuan Pham Anh).
- Fix undefined behavior in Avro format reader when reading numeric values that overflow the target column type. Now queries fail on overflows instead of silently producing incorrect values. #99697 (asyablue22).
- Fix parsing of shell-style quotes in arguments for the
executabletable function. #99794 (Nikita Semenov). - Fix false-positive abort in
NativeReaderwhen deserializing a Native format stream with a row-count mismatch: changed fromLOGICAL_ERRORtoINCORRECT_DATAso the error is handled as a data error rather than triggeringabort()in sanitizer/debug builds. #99822 (Rahul Nair). - Fix process abort in
Tuplecolumn deserialization when the serialization kind in the binary stream isDETACHED. #99823 (Rahul Nair). - Fix false
LOGICAL_ERRORexception during filesystem cache dynamic resize due to a race condition in SLRU sub-queue promotion. #99850 (Alexey Milovidov). - Fix async insert queries reporting zero
written_rows,read_rows, andresult_rowsinquery_logand client output. #99879 (Sema Checherinda). - Fix exception "Bad cast from type X to Y" in
KILL QUERYwhen the internal query against system tables returns columns wrapped inColumnConst. #99881 (Alexey Milovidov). - Fix logical error with correlated subquery within untuple argument. #99917 (Vladimir Cherkasov).
- Fixes an exception when calling
right,rightUTF8, or other substring functions with a length of INT64_MIN (-9223372036854775808), which previously caused undefined behavior due to integer overflow. The functions now correctly report an ARGUMENT_OUT_OF_BOUND error. #99934 (Jimmy Aguilar Mena). - Now ClickHouse should properly handle spark-style tables (where we have full absolute path for each file or relative path to common table path). Fixes #92348. #99935 (alesapin).
- Fix "Inconsistent AST formatting" exception for
ALTER TABLE ... MODIFY QUERYwith nested subqueries containingSETTINGSwhen theALTERitself also hasSETTINGS. #99938 (Nikita Mikhaylov). - Revert #97114 "Move join step row estimation before check for 1 child" due to suspected performance regression. #99957 (Alexander Gololobov).
- Fixes a bug where ClickHouse could skip files if the
Content-Lengthheader was missing in their HEAD request response (for example, because of decompressive transcoding in GCS). #99971 (Yarik Briukhovetskyi). - Fix assertion failure (exception in debug builds, incorrect results in release builds) when multiplying
NumericIndexedVectoraggregate states by an even integer constant, caused by self-XOR on aliased Roaring bitmaps inpointwiseAddInplace. #99976 (Desel72). - Prevent
Unexpected return typeexception in legacy filter pushdown through chainedJOIN USINGwhen key types change after join conversions. #99999 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception "Unexpected node type for table expression ... Actual IDENTIFIER" when a scalar subquery is used inside an unresolved table function argument, e.g.SELECT * FROM remote('localhost', view(SELECT 2 AS x), concat(x, (SELECT 1))). #100014 (Alexey Milovidov). - Fixed
INSERTwithVALUESfailing when the data was followed by a trailing SQL comment (--or/* */) on the next line. The comment is now skipped instead of being parsed as another row. #100016 (Pratima Patel). - Fix exception in
arrayRemovewhen comparing tuples with NULL components. #100017 (Alexey Milovidov). - Fix cross-user data leak in
system.asynchronous_inserts: any user withSELECTon the table could see pending async insert entries belonging to other users. Entries are now filtered by the current user, unless the user has theSHOW_USERSprivilege. #100024 (Shaohua Wang). - Fixes case where Time64 to UInt64 cast could clamp values to 24 hours. #100025 (Yarik Briukhovetskyi).
- Fix local server crash when CREATE DICTIONARY has a definition with list value containing non-existing function. #100036 (Yakov Olkhovskiy).
- Fix
CSV,MsgPackformat not being able to parseNullable(Tuple)properly. Closes #99753. #100038 (Nihal Z. Miaji). - Fix
CREATE VIEWfailing withUNKNOWN_IDENTIFIERwhen using a WITH function-expression alias (e.g.tuple(...)) as the right-hand side ofIN. #100042 (Peng). - Fix timeseries aggregate functions (e.g.
timeSeriesResampleToGridWithStaleness) failing withILLEGAL_TYPE_OF_ARGUMENTwhen used withinitializeAggregationorAggregatingMergeTreeunder parallel replicas. #100053 (Alexey Milovidov). - Make correctly processing negative values inside NumericIndexedVectorDataBSI. #100086 (Daniil Ivanik).
- Fix
accurateCastOrDefaultandto*OrDefaultfunctions not preserving Const column type for constant inputs. #100132 (Alexey Milovidov). - Omitted query parameters with
LowCardinality(Nullable(T))type now correctly default to NULL, same asNullable(T). #100144 (Denys Melnyk). - Fix use-of-uninitialized-value in StringSearcher.h. #100225 (Konstantin Bogdanov).
- Allow cancellation of scalar subqueries and other analysis-time pipelines via Ctrl+C. Previously, pressing Ctrl+C during a long-running scalar subquery had no effect until the subquery completed. Also fix the progress bar and JSON statistics to correctly report rows read during scalar subquery execution, both in
clickhouse-clientandclickhouse-local. Co-authored with @YjyJeff. #100230 (Raúl Marín). - Fixed a
LOGICAL_ERRORexception in queries involvingDynamiccolumns with cross joins and runtime filters, caused byColumnVariant::filtersharing variant column pointers instead of cloning them in thehasOnlyNullsoptimization path. Closes https://github.com/ClickHouse/ClickHouse/pull/100147. #100234 (Pavel Kruglov). - Fixed array of variant bug which may reinterpret data type upon calling
arrayFirst/arrayLastfunction. For example, previouslyArray(Variant(Date, Bool))is converted toBoolwhen the actual underlying variant type isDate. #100255 (timothygk). - A few minor changes to functions: h3 functions now validate boundaries better; readWKB checks the size limits (a new setting,
max_wkb_geometry_elements); random generator functions limit the maximum iterations in their computations. A follow-up for #93543. #100270 (Alexey Milovidov). - Fixed an issue where cutURLParameter could incorrectly skip parameters when they appeared as substrings of other parameters. #100280 (Nikita Semenov).
- Fix exception when Iceberg metadata file path setting contains a null byte. #100283 (Alexey Milovidov).
- Fixed the quadratic number of run queries when
distributed_index_analysisis used with predicates containingINsubqueries. #100287 (Anton Popov). - Fix "Block structure mismatch" exception when using
GROUP BY ... WITH TOTALS HAVINGcombined withUNION DISTINCTand nullable expressions. #100293 (Alexey Milovidov). - Fix LOGICAL_ERROR exception in
estimateCompressionRatiowhenblock_size_bytesparameter is extremely large. #100298 (Alexey Milovidov). - Fix "Inconsistent AST formatting" exception in debug builds when using
GROUP BY CUBE(...) WITH ROLLUPor similar combinations. #100376 (Alexey Milovidov). - Fix exception when creating a view with column aliases and
SELECT *orEXCEPT/INTERSECTqueries. #100386 (Alexey Milovidov). - Fix
DROP TABLEhanging indefinitely on Kafka engine tables when consumers are stuck in a rebalance after a heartbeat error. #100388 (Alexey Milovidov). - Fix
ReadBuffer is canceled. Can't read from it.exception in backup/restore operations using zip archives. #100400 (Alexey Milovidov). - Fix
TOO_MANY_ROWSexception forSELECT count()queries withmax_rows_to_read/force_primary_keywhen data is split across multiple parts with non-aligned granule boundaries. #100408 (Alexey Milovidov). - Fix
system.completionsto correctly filter databases, tables, and columns by access rights in all grant combinations: per-table, per-db, and per-column revoke. #100432 (Shaohua Wang). - Fix SEGFAULT in NuRaft due to race condition. #100444 (Pablo Marcos).
min/max/argMin/argMaxnow treat NaN consistently withORDER BY: NaN is always skipped (returned only when all values are NaN). Previously, results depended on NaN position in the data due to IEEE 754 unordered comparison semantics. #100448 (Raúl Marín).- Fixed a copy-paste bug where
delta_lake_snapshot_end_versionset withoutdelta_lake_snapshot_start_versionwas silently ignored instead of producing aBAD_ARGUMENTSerror. #100454 (Mohammad Lareb Zafar). StorageRabbitMQ::shutdownis not idempotent (it unconditionally accesses weak pointers and then destroys the corresponding shared pointers), but is now called twice: once inStreamingStorageRegistryand then inDatabaseCatalog. This fix makes the method idempotent and adds defensive null checks. #100455 (Miсhael Stetsyuk).- Fix
LOGICAL_ERRORexception when usingaccurateCastOrNullwithQBittarget type. #100470 (Raufs Dunamalijevs). - Fix LOGICAL_ERROR exception "Stream ... not found" when inserting into a table with nested
Array(JSON)columns in wide parts withoptimize_on_insert=0. #100475 (Pavel Kruglov). - Validate file entry paths in backup metadata to reject path traversal, absolute paths, and empty names during
RESTORE. #100483 (Pablo Marcos). - Fix
LIMIT m OFFSET n WITH TIESsyntax not working. This syntax is equivalent toLIMIT n, m WITH TIESwhich already worked. #100491 (Nihal Z. Miaji). - Fix exception "No set is registered for key" when using
INwithNullable(Tuple)columns that have named fields andLowCardinalityelements. #100523 (Alexey Milovidov). - Fix heap-buffer-overflow in usearch
sorted_buffer_gt::insert()that could crash or silently corrupt memory during vector similarity search. #100537 (Dustin Healy). - Fix
EXECUTE ASignoringFORMATandINTO OUTFILEclauses specified in the query. #100538 (pufit). - Fix inconsistent AST formatting for SAMPLE with query-level OFFSET. Closes #100576. #100579 (Pavel Kruglov).
- Fix polaris catalog with azure. Since 25.12 this catalog with azure started to add bucket at the beginning of the path. For example
abfss://polaris-polaris@<some_url>.windows.net/polaris-polaris/<other-path>instead ofabfss://polaris-polaris@<some_url>.windows.net/<other-path>. This PR cuts bucket in the path. #100583 (Konstantin Vedernikov). - Fix type mismatch exception in transform when default column is const on some blocks. Closes #100574. #100616 (Pavel Kruglov).
- Fixes NOT_FOUND_COLUMN_IN_BLOCK cases where the projection SELECT part has columns that do not exist in the original SELECT part of the query. Closes #100194. #100623 (Yarik Briukhovetskyi).
- Validate Npy format shape dimensions against file size and overflow limits to prevent denial of service from crafted
.npyfiles with unreasonably large dimensions. Also reject empty shapes and cap per-row memory to 2 GiB. #100625 (Raúl Marín). - Fix
session_timezonebeing ignored when parsingDateTimevalues during async inserts (TCP) and all inserts over HTTP. #100647 (Sema Checherinda). - Allow passing sharding key to
cluster()andclusterAllReplicas()table functions when using a table function as the source (e.g.cluster('name', view(...), sharding_key)). #100665 (Sergey Veletskiy). - Fix server crash (assertion failure) when using parametric aggregate functions with Array combinator and NULL arguments, such as
quantileIfArrayArray(0.5)([[NULL]], [[1]]). #100679 (nerve-bot). - Fix exception when computing common supertype for empty and non-empty tuples with
use_variant_as_common_typeenabled. #100699 (Antonio Andelic). - Server no longer fails to start when an Azure blob storage disk is configured but the endpoint is temporarily unreachable (e.g. DNS failure). #100701 (Raúl Marín).
- Fix undefined behavior in
positiveModulowhen the unsigned divisor does not fit in the signed result type. #100705 (Raúl Marín). - Fix server crash (logical error "Unexpected return type from __topKFilter") when
use_top_k_dynamic_filteringis enabled and theORDER BYcolumn hasDynamicorVarianttype. #100742 (Groene AI). - Fix server crash when using
has()function with PREWHERE/WHERE on a Tuple key containing LowCardinality elements. #100760 (Groene AI). - Fix
file_offset_of_buffer_end <= getFileSize()assertion failure (exception in debug builds) when reading fromLogorStripeLogtables on S3 object storage with concurrent writes. #100763 (Alexey Milovidov). - Fix an exception in the statistics selectivity estimator when a WHERE clause contains a function expression (e.g. toDecimal64(col, 3)) on a table with statistics enabled. The estimator now skips such predicates instead of attempting an invalid type cast. #100764 (Han Fei).
- Fixes a rare case where join with reordering can produce a wrong result. #100790 (Yarik Briukhovetskyi).
- Fix incorrect
AggregateFunctionargument types in optimized trivial count, which causedNUMBER_OF_ARGUMENTS_DOESNT_MATCHexception when querying expressions likecount(v0 + v1)on distributed tables. #100794 (YjyJeff). - Some catalogs can show some secrets in the
SETTINGSsection ofselect * from system.databasesquery result. This PR prevents such behavior. #100800 (Konstantin Vedernikov). - Fix undefined behavior (signed integer overflow) in
toStartOfIntervalwhen using Week, Quarter, or Year intervals with an origin argument and extreme interval values. #100817 (Raúl Marín). - Fix
If,Distinct,DistinctIf,IfStateaggregate function combinators withTuplereturn type and one or moreNullableargument not being able to read older serialized states after introduction ofNullable(Tuple). Closes #98917. #100826 (Nihal Z. Miaji). - Fix segfault in s3Cluster and distributed queries due to connection pool use-after-free. #100837 (Konstantin Bogdanov).
- Fix null pointer dereference segfault when loading dictionaries during server shutdown.
Context::getUserDefinedSQLObjectsStorage(dereferencesuser_defined_sql_objects_storage) is called by dictionary threads concurrently with the main thread callingContext::shutdown(setsuser_defined_sql_objects_storageto null). We need to make sure we disable future updates in the dictionaries loader, kill the currently running dictionary queries and join the dictionary loading threads - all before runningContext::shutdown. Similar to what we do with normal queries. #100839 (Miсhael Stetsyuk). - Fix buffer overflow in
ULIDStringToDateTimewhen input contains non-ASCII bytes. #100843 (Konstantin Bogdanov). - Fix crash (
LOGICAL_ERROR) when querying aMergetable (ormerge()table function) that wraps multiple tables including aDistributedtable, withdistributed_group_by_no_merge=1enabled. #100859 (Groene AI). - Cast_keep_nullable when enabled will not throw when casting dynamic null to variant. #100864 (Seva Potapov).
- Fix
clickhouse-keeper-clientget,exists, andlscommands printing duplicatewatch_iderror messages to stdout instead of stderr. #100893 (Mohammad Lareb Zafar). - Fix exception in
intDiv/intDivOrZeroon arrays of nullable tuples, e.g.SELECT intDiv([divide((1, 2), ... AND NULL)], 2). #100895 (Raúl Marín). - Evaluate engine arguments for
StorageAliasbefore storing the definition, so that expressions likecurrentDatabase()are resolved to literals before being saved to the database. #100902 (Nikolay Degterinsky). - Fix
processAndOptimizeTextIndexFunctionswhenquery_plan_merge_expressions = 0, whereExpressionStepis directly aboveReadFromMergeTree. Fixes #100879. #100909 (Jimmy Aguilar Mena). - Update replxx to include fix for out-of-bounds access in do_complete_line. #100925 (Azat Khuzhin).
- Fix wrong results when JOIN with shard-by-PK optimization uses query condition cache and some parts are filtered out by cached conditions. #100926 (Groene AI).
- Fix
divideandintDivreturningILLEGAL_DIVISIONwhen used in filter expressions during index analysis in some cases. #100928 (Nihal Z. Miaji). - Fixed "Target table doesn't exist" errors for materialized views with inner tables during async startup, caused by incorrect startup dependency ordering. #100946 (Nikolay Degterinsky).
- Fix undefined behavior (signed integer overflow) in parseDateTimeBestEffort when parsing datetime strings with more than 18 fractional-second digits. #100948 (Vasily Chekalkin).
- Fixed a crash when using a text search index with an
INclause containing a tuple subquery, e.g.WHERE (id, str) IN (SELECT (id, str) FROM ...), or when the number of columns in the subquery does not match the tuple on the left side ofIN. #100959 (Anton Popov). - Fixed crash when building a polygon dictionary from a
MergeTreetable that uses sparse columns serialization. #100964 (Anton Popov). - Fix logical error "Invalid action query tree node" when using
INTERSECT ALL/UNION ALLwith constant-folded expressions. #100977 (Alexey Milovidov). - Fix
sumCountOrDefaultaggregate function with one or moreNullableargument not being able to read older serialized states after introduction ofNullable(Tuple). Closes #100882. #101021 (Nihal Z. Miaji). - Fix crash (
Logical error: isConst/isSparse/isReplicated assertTypeEquality) in merge algorithms when lazy column replication (enable_lazy_columns_replication) producesColumnReplicatedcolumns that flow into merge-sort pipelines with late-arriving inputs. #101036 (Groene AI). - Fix incorrect
UNKNOWN_IDENTIFIERerror when the same alias is used for multiple expressions inSELECT; the correctMULTIPLE_EXPRESSIONS_FOR_ALIASerror is now reported. #101040 (Alexey Milovidov). - Fix ALIAS columns with
DateTime/DateTime64types not applying timezone conversion when the declared timezone differs from the expression timezone. #101043 (Alexey Milovidov). - Fix row policies not being recorded in
query_logfor views, subqueries, andINSERT ... SELECT. Even though row policies were applied during query planning, they were not propagated from sub-planners to the parent planner for logging. Row policies (for logging only) are now kept inQueryAccessInfoso that both planners and sub-planners can populate them. #101044 (Narasimha Pakeer). - Fix exception in
DirectJoinMergeTreeEntitywhen pipeline blocks containColumnConstcolumns that are merged with regular columns. #101046 (Alexey Milovidov). - Fix spurious space in CTE column alias formatting (
WITH t (a, b)→WITH t(a, b)). #101049 (Alexey Milovidov). - Fix
remote/clustertable functions failing with nested table functions likemergewhen the analyzer is enabled. #101055 (Alexey Milovidov). - Fix
OFFSETbeing applied twice in distributed queries whenprefer_localhost_replica=1, producing fewer rows than expected. #101071 (Nihal Z. Miaji). - Fix crash when using the
Regexpformat with an invalid regular expression informat_regexpsetting. #101074 (Nihal Z. Miaji). - Fix "Illegal type Decimal64 of start parameter" error for timeseries aggregate functions when using
serialize_query_plan=1with parallel replicas. #101083 (Groene AI). - Fix exception in
optimizeLazyMaterializationwhen a projection with PREWHERE is used withORDER BY ... LIMIT. #101115 (Anton Popov). - Fix server crash (SIGABRT) when using aggregate functions with the internal-only
Nullcombinator (e.g.sumNull,avgNull) andaggregate_functions_null_for_empty = 1setting enabled. #101147 (Groene AI). - Fix a use-after-free in the filesystem cache write path that could cause reads from freed memory when logging completed file segments (detected by MemorySanitizer in BuzzHouse). #101161 (Groene AI).
- Fix server crash with "Trying to attach external table to a ready set without explicit elements" when distributed index analysis encounters a GLOBAL IN predicate whose set was built without explicit elements. #101178 (Groene AI).
- Fix
MAX/MINaggregate functions onDecimalcolumns returning incorrect results when JIT compilation is enabled (after the compilation threshold is reached). #101203 (Raúl Marín). - Fix
minmax_count_projectionand trivialCOUNT(*)optimizations being permanently disabled after a lightweight delete, even after all parts with a mask of lightweight delete were merged away. #101212 (Anton Popov). - Fix a case which can lead to
Having zero bytes, ...logical error from cache arising from a remote object being overwritten in betweenlistandreadwhich previously resulted in a stale object metadata. #101219 (Kseniia Sumarokova). - Fix server crash (LOGICAL_ERROR: Bad cast from ColumnVector to ColumnLowCardinality) when querying a MergeTree table with
ORDER BY CAST(lc_column, 'Type')wherelc_columnhas a LowCardinality type. #101220 (Groene AI). - Fix cleanup of stale processing nodes in
S3Queue. #101230 (Kseniia Sumarokova). - Fix UB in mergeTreeAnalyzeIndexes() in case of invalid optimizations argument. #101253 (Azat Khuzhin).
- Fix
Logical error: 'partitions_count > 0'exception when performing consecutiveALTER TABLE UPDATEon a partitioned Iceberg table. #101278 (Desel72). - Fix wrong query results when a large integer constant (e.g. 256, 2147483648) is used as a boolean predicate in a WHERE clause with AND on MergeTree tables. For example,
SELECT count() FROM t WHERE (2147483648 > b) AND 2147483648would incorrectly return 0 instead of matching all rows. #101287 (Groene AI). - Fix insert-select from delta lake cluster with replicated merge tree. #101299 (Konstantin Vedernikov).
- Fixed crash with "Logical error: Reading from materialized CTE before materialization" when a scalar subquery references a chain of dependent materialized CTEs. #101305 (Groene AI).
- Fix data race on
storage_idinIStorage::getDependentViewsByColumn. #101385 (Nikolay Degterinsky). - Fix BACKUP FROM SNAPSHOT AST formatting and cloning. #101405 (Pablo Marcos).
- Fix LOGICAL_ERROR crash "Current component is empty" when querying
system.part_moves_between_shardswithenforce_keeper_component_trackingenabled. #101462 (Groene AI). - Fix segmentation fault in DataTypeDynamic::create() when the fuzzer generates a malformed Dynamic type AST. #101464 (Groene AI).
- Throw an error when
delta_lake_snapshot_versionor CDF version settings are used without DeltaKernel enabled, instead of silently returning wrong data. #101489 (Desel72). - Fix
NOT_FOUND_COLUMN_IN_BLOCKexception when using ARRAY JOIN with JOIN USING andanalyzer_compatibility_join_using_top_level_identifiersetting enabled. Close #101240. #101507 (Vladimir Cherkasov). - Fix Iceberg INSERT retry loop failing when the table was created with
iceberg_metadata_file_pathand the target metadata version already exists. #101548 (Groene AI). - Strip Nullable from result column in arrayIntersect and related functions to avoid serialization/deserialization mismatch. #101569 (George Larionov).
- Fix server crash (LOGICAL_ERROR) when SELECT-ing from a materialized view backed by an IcebergLocal table engine. #101577 (Groene AI).
- Fix incorrect error message when calling
intExp10with NaN argument — it saidintExp2instead ofintExp10. #101582 (Krishna Chaitanya). - Fix
allow_statistics=0not blockingALTER TABLE ADD STATISTICSandALTER TABLE DROP STATISTICSafter refactoring in #100288. #101585 (Krishna Chaitanya). - Fix
KeeperMapCREATE TABLEfailing with "Cannot create metadata for table" when leftover ZooKeeper nodes from a pre-25.1 partial drop are missing thedrop_lock_versionnode. #101623 (Antonio Andelic). - Fix possible logical error during reading Map subcolumns. Closes #100769. Closes #101336. #101641 (Pavel Kruglov).
- Fix exact subcolumn match priority over prefix match in
getSubcolumnDatato avoid possible crash. Closes #101271. #101645 (Pavel Kruglov). - Fix crash (LOGICAL_ERROR: "ColumnUnique can't contain null values") when comparing a
LowCardinalitycolumn with aVariantNULL constant whileuse_variant_default_implementation_for_comparisonsis disabled. #101690 (Groene AI). - What: Added empty-stream guard to Bzip2ReadBuffer so it returns EOF instead of throwing UNEXPECTED_END_OF_FILE when the inner stream is empty. #101691 (ClickGap AI Bot).
- What: Fixed the inverted description text for the
alterablecolumn insystem.s3_queue_settingsandsystem.azure_queue_settings— swapped0and1meanings to match the actual code behavior. #101703 (ClickGap AI Bot). - Fix positiveModulo(tuple, number) incorrectly dispatching to division instead of modulo. #101709 (ClickGap AI Bot).
- Fixes a crash when
thread_pool_sizeis configured on a cache-wrapped disk. Previously,FileCacheSettings::loadFromConfig()rejectedthread_pool_sizeas an unknown setting, preventing the server from starting. The setting is a validIDiskparameter that controls the number of threads used for disk-to-disk copy operations during background part moves. #101712 (Francisco). - Fix
RANGE_HASHEDdictionary creation silently accepting a non-existentMAXrange attribute and using the wrong type configuration when min and max range attributes had different types. The bug was a copy-paste error inbuildRangeConfigurationthat looked upmin_attr_nameinstead ofmax_attr_namefor the max attribute. #101732 (Yakov Olkhovskiy). - Fix use-after-free crash in CPU lease scheduler when the wait timer outlives the worker thread whose
ProfileEvents::Countersit references. #101761 (Antonio Andelic). - Fixes bug in arrayLevenshteinDistanceWeighted and arraySimilarity functions. Closes #101725. #101767 (Mikhail f. Shiryaev).
- Fix Prometheus Query API ignoring POST form bodies. #101794 (James Cunningham).
- Fix exception escaping from S3
Client::~Clientdestructor causing server termination. #101798 (Gagan Dhakrey). - Fix use-after-scope in parallel deserialization of
Objecttype dynamic paths, which could cause crashes when reading tables with many dynamic paths. #101823 (Antonio Andelic). - Fixed incorrect output in function
formatDateTimewith formatter%Wwith certain (non-default) formatting settings. #101847 (Robert Schulze). - Fix
shouldPatchFunctionfalse negative inSYSTEM INSTRUMENT ADDwhen the search string first appears inside a template argument of the demangled symbol name. #101885 (Pablo Marcos). - Fix UDF registry loss when ZooKeeper session expires during periodic refresh — all user-defined functions could become unavailable until a full refresh succeeds. #101891 (Nikita Fomichev).
- Fixed
system.codecsdescription forAES_256_GCM_SIVto reportAES-256instead ofAES-128. #101917 (Jimmy Aguilar Mena). - Fix using wrong extremes in min-max index created on JSON column leading to wrong query result. Closes #101700. #101918 (Pavel Kruglov).
- The
splitByStringtokenizer now rejects empty separator strings. #101928 (Robert Schulze). - Fix
materialize_skip_indexes_on_merge=falsenot suppressing text (full-text) indexes during merge. Previously, only non-text skip indexes (minmax, set, bloom_filter) were suppressed; text indexes continued to be built, wasting CPU and I/O. #101932 (Groene AI). - The
sparseGramstokenizer generated longer tokens than the provided max length (this was due to a hard-coded+2in the implementation). #101934 (Elmi Ahmadov). - Fix SIGSEGV in
MergeTreeDataPartWriterWide::cancelwhen a stream constructor throws duringaddStreams, leaving a null entry incolumn_streams. #101936 (Antonio Andelic). - Fixes an exception when querying Merge or Distributed tables with a full-text index and combined filter conditions that mix
has*Tokenswith LIKE, whilequery_plan_direct_read_from_text_indexis enabled. #101939 (Jimmy Aguilar Mena). - Fix undefined behaviour when parsing native protocol query packets with invalid
QueryProcessingStagevalues. #101972 (Raúl Marín). - Close TCP connection when an exception occurs during initial query parsing to prevent reading garbage from a desynchronized stream. #101989 (Raúl Marín).
- Fix SLRU race bug in filesystem cache 26.1+, which can lead to space reservation logical error. In debug build it can also lead to failed assert:
'Previous state is Evicting, but expected state to be Active while setting Evicting flag for 2c1e3484ecdc6b78a8978fa5b17c5097:0:339 (state: Evicting)'.. #101991 (Kseniia Sumarokova). - Fix exception when casting a string with trailing data to empty
Tuple()type. #102011 (Alexey Milovidov). - Fixes incorrect row ordering in queries that use ORDER BY with the grace_hash join algorithm. Affected queries could return results in the wrong order, producing silently incorrect output. #102036 (János Benjamin Antal).
- Fixes a LOGICAL ERROR (Unexpected size of index type) that could occur in RIGHT JOIN and FULL JOIN queries when the
max_bytes_in_joinsetting was configured. #102042 (Jimmy Aguilar Mena). - Fixes cases where Time with negative values was returning wrong result on comparison with DateTime. Closes #101670. #102056 (Yarik Briukhovetskyi).
- Fix crash in UDF refresh caused by
ZooKeeperRetriesControlretrying on a stale (expired) ZooKeeper session without renewing it. #102059 (Nikita Fomichev). - Fix missing spaces when formatting unlock snapshot. close https://github.com/clickhouse/clickhouse/issues/101723. #102063 (Han Fei).
- Fix crash (SIGSEGV) when querying a view with a WHERE clause and the inner query produces columns with different types than the view metadata (e.g. Nullable from LEFT JOIN with
join_use_nulls). #102085 (Miсhael Stetsyuk). - Fix
VectorSimilarityIndexCacheentries never being evicted after part removal due to mismatched cache keys. #102152 (Seva Potapov). - NACK broken messages when using rabbitmq storage. #102157 (Seva Potapov).
- Fix logical error when parsing incorrect empty tuple string. #102289 (Nihal Z. Miaji).
- Fix incorrect aggregation results (duplicate rows) when using
optimize_aggregation_in_order=1with GROUP BY columns ordered differently from the table's sorting key. #102299 (Groene AI). - Fix crash in
IcebergLocalALTER TABLE ... UPDATEwhen using Avro format, caused byLowCardinality/Nullablewrapper types not being unwrapped before serialization. #102337 (Desel72). - Fixed a segmentation fault in mutations on materialized columns without an expression. Closes #102185. #102342 (zoomxi).
- Coalescing merge tree fix for array type. This closes #89509. #102384 (Konstantin Vedernikov).
- Fix segfault (or LOGICAL_ERROR in debug builds) when reading Parquet files with bloom filter push down enabled and WHERE clause equality/inequality conditions. The crash occurred due to an out-of-bounds memory access in the Parquet prefetcher's bloom filter data retrieval, and could also cause non-deterministic wrong query results. #102385 (Groene AI).
- Fix
LOGICAL_ERRORabort during SLRU filesystem cache dynamic resize caused by shared eviction statistics across sub-queues and incorrect recovery path for failed candidates. #102396 (Antonio Andelic). - Fix failure to initialize on a fresh replica Alias tables without a target table in the Database Replicated. Closes #101320. #102397 (Nikolay Degterinsky).
- Fix out-of-bounds read in string search functions (
countSubstrings,position, etc.) when searching for a needle consisting entirely of null bytes. #102401 (Raúl Marín). - Full text index settings (
enable_full_text_index,allow_experimental_full_text_index,use_skip_indexes_on_data_read) are no longer disabled when thecompatibilitysetting points to a version older than 26.1. Previously this could preventSharedDatabaseCatalogfrom creating tables with text indexes. #102422 (Nikita Fomichev). - Fix out of bounds read in
printfwith trailing%. #102472 (Raúl Marín). - Fixes a chassert exception
ReadBuffer is canceledin debug builds in AsynchronousMetrics, caused by rewind not resetting the buffer cancellation flag. #102524 (Yuri Fedoseev). - Fixed
hasToken/hasTokenOrNullwith separator-only needles (e.g.'()','!!!') on columns with a text index: previously the index silently skipped all granules instead of throwingBAD_ARGUMENTS(forhasToken) or returningNULL(forhasTokenOrNull). #102544 (Jimmy Aguilar Mena). - Fix OOMs on huge multi requests in the keeper. For OpenTelemetry tracing, we unconditionally allocate >1 KiB for OpenTelemetry spans in
ZooKeeperRequestobjects - meaning, for really huge multi requests, we try to allocate >10 GiB extra memory. To fix this, we now keep shared data in static memory and usestd::unique_ptroverstd::optionalinZooKeeperOpentelemetrySpans. #102586 (Miсhael Stetsyuk). - Fix
NamedCollectionCurrentMetric being inflated byCREATE NAMED COLLECTION IF NOT EXISTSon existing collections, and not being initialized for collections loaded from config or SQL storage at startup. Closes #102507. #102598 (Pablo Marcos). - Fix exception in
getStructureOfRemoteTablewhen local shard returns empty columns due to concurrent DDL. #102604 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception when multiple concurrentCREATE TABLE IF NOT EXISTSqueries target the sameS3Queuetable on a Shared database. #102610 (Nikita Taranov). - Fix LOGICAL_ERROR crash "Unexpected number of rows in column subchunk" in native Parquet V3 reader when reading nullable columns with a WHERE filter. #102628 (Groene AI).
- Fix
AzureWriteMicrosecondsprofile event description saying "read" instead of "write". #102639 (Miсhael Stetsyuk). - Bug with row policy that gives 'Not found column in block' exception in some special cases. #102648 (Yarik Briukhovetskyi).
- Fixed a server exception in ClusterDiscovery when a static cluster (defined in config) temporarily had no live nodes. #102661 (Kseniia Sumarokova).
- Fix wrong date data type inference in case of overflow after timezone adjustment. Closes #102601. #102674 (Pavel Kruglov).
- Fix
SYSTEM WAIT VIEWhanging forever when the refreshable materialized view is dropped while the wait is in progress. #102681 (Nikolay Degterinsky). - Fix CASE with Dynamic expression returning ELSE for all rows. Closes #102511. #102684 (Pavel Kruglov).
- Fix flattened Dynamic type serialization with binary encoded data types. Closes #101911. #102692 (Pavel Kruglov).
- Fix format_schema_source='query' silently ignoring multi-row results. Closes #101905. #102698 (Pavel Kruglov).
- Report actual exit code via SSH client instead of mapping all errors to
1. Closes #101741. #102700 (Konstantin Bogdanov). - Fix losing HTTP headers for dynamic/predefined query handlers. Closes #101846. #102706 (Konstantin Bogdanov).
- Apply Poisson sampling correction to collapsed jemalloc heap profiles to match jeprof output. Previously the collapsed format underestimated actual allocation sizes by not accounting for the sampling probability. #102759 (Antonio Andelic).
- Fix the crash in the function
hasPhrasewith aNULLargument. #102802 (Nikita Taranov). - Fix server crash (SIGSEGV) when reading Avro files with recursive schemas containing cyclic symbolic type references. Now such schemas are detected and rejected with a clear error message instead of crashing. #102853 (Groene AI).
- Fix server crash (LOGICAL_ERROR assertion) when a function on a
Variantcolumn hits a memory limit or other non-type-conversion exception during result casting inFunctionVariantAdaptor. The exception is now propagated correctly instead of being misclassified as an internal error. #102855 (Groene AI). - Fix server crash in debug/sanitizer builds when
std::length_erroris thrown during schema inference (e.g., from extremeinput_format_msgpack_number_of_columnsvalues or malformed input data). #102859 (Groene AI). - Make null representation in serialization of replicated and sparse columns respect settings (e.g. format_tsv_null_representation). #102888 (Hechem Selmi).
- Backported in #103499: Fix S3 requests failing with
ios_base::clear: unspecified iostream_category errorinstead of being retried, caused by PocoBufferedStreamBuf::flushBuffernot handling short writes from the socket layer. #102894 (Sema Checherinda). - Fix
minmax_count_projectionand trivialCOUNT(*)optimizations being permanently disabled after a lightweight delete, even after all parts with a mask of lightweight delete were merged away. #102900 (Anton Popov). - Fix random crashes in jemalloc due to LTO. #102913 (Azat Khuzhin).
- Optimize row policy OR-chains to IN in the new analyzer. #102915 (Azat Khuzhin).
- Fix jemalloc metadata corruption caused by page cache freeing with wrong alignment that may lead to crashes. #102918 (Azat Khuzhin).
- Plain INSERTs without materialized views no longer request excessive ConcurrencyControl slots and threads (
max_threadsinstead ofmax_insert_threads), preventing CC slot starvation and thread count blowup on clusters with high INSERT throughput. #102961 (Sema Checherinda). - Reintroduce ArrowMemoryPool to allow throwing MEMORY_LIMIT_EXCEEDED to avoid kernel OOM. #102999 (Azat Khuzhin).
- Fix
cast_string_to_date_time_modebeing ignored forCASTtoNullable(DateTime). Closes #101840. #103035 (Pavel Kruglov). - Added support for
ALIAScolumns in text index direct read optimization. #103037 (Anton Popov). - Backported in #103454: Fix
SELECT DISTINCTsilently returning incomplete results when an aggregate projection matched the query and some parts of the table had no projection data (e.g. the projection was added on a table that already held data, andMATERIALIZE PROJECTIONwas not run). Closes #102951. #103052 (Nihal Z. Miaji). - Fix wrong results returned by
WHERE x AND toNullable(N)onMergeTreetables whenNis an integer wider thanUInt8(e.g.256,65535,2147483648, or any negative integer). The filter incorrectly discarded all rows becausesplitFilterNodeForAllowedInputsused aNULLzero when converting theNullableremainder of a reducedANDto boolean, turning the comparison intoNULLunder three-valued logic. #103077 (Groene AI). - Fixed incorrect argument type reported in error messages of string search functions (e.g.
locate,position) when arguments are passed in swapped order (locate(needle, haystack)withfunction_locate_has_mysql_compatible_argument_order = 1). #103102 (Alex Kuleshov). - Fix waitForPause hanging indefinitely when disableFailPoint is called with no thread paused at the failpoint. #103119 (Shaohua Wang).
- Cap pre-auth TCP Hello packet strings to 64 KB and add
handshake_timeout_millisecondsserver setting to limit total handshake time, preventing unauthenticated clients from consuming excessive memory or holding threads indefinitely. #103284 (Sema Checherinda). - Fix Parquet ColumnIndex stats min_value > max_value for String columns. #103334 (Saurabh Kumar Ojha).
- Check for malformed flattened Dynamic data in Native format. #103392 (Pavel Kruglov).
- Populate
_timecolumn fromurltable function. #103437 (Nikita Taranov). - Fix SVE detection using SVE instructions when unavailable. #103568 (Raúl Marín).
Build/Testing/Packaging Improvement
- Libstemmer (Snowball) dependency now uses newer version v3.0.1. #99256 (Jimmy Aguilar Mena).
- Randomize settings in datastore-test:
use_skip_indexes_for_top_k,use_top_k_dynamic_filtering,query_plan_max_limit_for_top_k_optimization. #91782 (Nikita Fomichev). - Implement a stress test for functions, checking the soundness of their various properties. #93543 (Michael Kolupaev).
- Provide own CMake configuration for
llvm-projectinstead of importing upstream one. #97453 (Konstantin Bogdanov). - Randomize more
optimize_*settings in the test infrastructure to improve coverage of query optimization passes. #97547 (Alexey Milovidov). - Use Rust toolchain nightly-2026-03-22. #98602 (Konstantin Bogdanov).
- Use
wasmtimev42.0.1. #98603 (Konstantin Bogdanov). - Use
llvm-project22.1.1. #98882 (Konstantin Bogdanov). - Replace
SANITIZE_COVERAGE(custom sanitizer callbacks, symbol-level granularity) with LLVM source-based coverage (WITH_COVERAGE,-fprofile-instr-generate -fcoverage-mapping) for the nightly per-test coverage pipeline. The server now reads its own coverage mapping from ELF sections at startup and collects(file, line_start, line_end)tuples per test via a newSYSTEM SET COVERAGE TEST 'name'command. Test selection in targeted CI checks uses line-range queries against a newchecks_coverage_linesCIDB table and ranks candidate tests by how many changed diff lines they cover. #99513 (Nikita Fomichev). - Fix llvm-libc link error with -O0 build. #100023 (Zheguang Zhao).
- Fixed two error messages on container startup in case the configuration did not contain the
logger.logandlogger.errorlogsettings (e.g. when all log messages are supposed to go to STDOUT/STDERR). #100239 (Simon). - Prefer
ld64.lldover Apple'sld(cctools-port ld64) for macOS builds. This should significantly reduce Darwin link times, as cctools-port's ld64 is very slow with-ffunction-sectionsand-dead_strip. Falls back toldifld64.lldis not available. #100275 (Alexey Milovidov). - Tests to ensure that directories do not register any secrets (REST + Glue). #100307 (Konstantin Vedernikov).
- Repeat recently modified tests with different randomized settings. #100385 (Alexey Milovidov).
- Track
#embedfile dependencies in CMake and enable ccache depend mode for correct rebuilds. #100411 (Alexey Milovidov). - Add correctness tests for TPC-H queries. #100580 (Raufs Dunamalijevs).
- Use
aws-sdk-cpp1.11.771. #100582 (Konstantin Bogdanov). - Allow performance test XMLs to reference external SQL query files and settings via file attribute. #100747 (Raufs Dunamalijevs).
- Fix compilation with
-march=x86-64-v4by adding missingTargetSpecific.hinclude inLowerUpperImpl.h. #100932 (Alexey Milovidov). - Fix build on gentoo by adding --no-default-config to cxxflags. #100973 (Isak Ellmer).
- Added
utils/auto-bisect/— a shell-based bisection framework that downloads pre-built CI binaries and runs a user-supplied test script to find the first commit that introduced a regression, without requiring a local build. #100989 (Nikita Fomichev). - Disable ThinLTO by default in CMake so that local developer builds no longer implicitly enable it. CI release builds are unaffected since they explicitly pass
-DENABLE_THINLTO=1. #101041 (Alexey Milovidov). - Add TPC-DS SF1 benchmark to performance tests. #101209 (Raufs Dunamalijevs).
- Added stateless tests for MergeTree lightweight deletes covering:
has_lightweight_deleteflag lifecycle,COUNT(*)correctness withoptimize_trivial_count_query,MATERIALIZED/DEFAULTcolumn integrity,ReplicatedMergeTreeflag recovery,read_in_orderwith deleted rows, multiple delete/merge cycles,_row_existscolumn hiding, predicate variety, andALTER DELETERBAC enforcement. #101792 (Nikita Fomichev). - Distroless Docker images are now published with ubuntu and alpine variants for tagged releases. #101941 (Rahul Nair).
- Stack traces now show clean bare relative paths (e.g.
src/Common/Exception.cpp) instead of paths polluted with the build directory (e.g../ci/tmp/fast_build/./src/Common/Exception.cpp). #102000 (Raúl Marín). - Add a CI style check that rejects files larger than 5 MB committed to the repository, with a whitelist for existing legitimate test data. Remove unused 14 MB
zookeeper_log.parquet. #102080 (Raúl Marín). - Remove ~400 unused
#includedirectives from headers to reduce compilation times. #102585 (Raúl Marín). - Use
wasmtimev43.0.1. #102603 (Konstantin Bogdanov). - Use
openssl3.5.6. #102606 (Konstantin Bogdanov). - Use
xz5.8.3. #102607 (Konstantin Bogdanov). - Upgrade distroless Docker image base from Debian 12 (glibc 2.36, OpenSSL 3.0) to Debian 13 (glibc 2.41, OpenSSL 3.5), reducing CVE surface to zero reachable vulnerabilities. #101678 (Rahul Nair).
ClickHouse release 26.3 LTS, 2026-03-26. Presentation, Video
Backward Incompatible Change
- Downgrading after upgrading may cause data loss. Propagate data types serialization versions to nested data types. For example, String serialization version
with_size_streampreviously was applied only on top-level String columns and Tuple elements. Now it's applied to any String type inside any nested type likeArray/Map/Variant/JSON/etc. This behaviour is controlled by MergeTree settingpropagate_types_serialization_versions_to_nested_typesthat is now enabled by default. After this change, newly created data parts cannot be read by older versions, but old parts can be read on new version with no problems. Upgrade is safe, but downgrade is not — if you need to roll back after upgrading to 26.3, data written by 26.3 in columns with nested types will be unreadable! See #101429 for details. #94859 (Pavel Kruglov). - Remove the
hypothesisskip index type. It was an obscure, experimental feature with limited practical use. Creating tables withINDEX ... TYPE hypothesiswill now produce an error. #96874 (Alexey Milovidov). - Remove the experimental
detectProgrammingLanguagefunction. #99567 (Alexey Milovidov). - Fix
NOToperator precedence to match the SQL standard:NOTnow binds looser thanIS NULL,BETWEEN,LIKE, and arithmetic operators. For example,NOT (x) IS NULLis now parsed asNOT (x IS NULL)instead of(NOT x) IS NULL. This may change the result of queries that relied on the previous (non-standard) behavior. #97680 (Alexey Milovidov). - Corrects the metadata of normal projections so that projections with multi-column sorting keys are properly recognized. Builds on top of #90429. #91352 (Amos Bird).
- Fixed skip index files not respecting replace_long_file_name_to_hash setting, causing "File name too long" errors and broken index reads for indices with long names. Skip index filenames are now hashed when they exceed max_file_name_length, similar to column files. This is backward compatible (new servers read old parts), but downgrading (or old servers during a rolling upgrade) may cause long-named indices to be ignored. #97128 (Raúl Marín).
- Turn on async insert by default. ClickHouse will be batching all small inserts by default now. This setting is set under compatibility. If you set
compatibility=<version less than 26.2>then default value would be the previous one,false. You can turn off/on async inserts at several levels: in the config in users profiles, for the session, for the query, or for the MergeTree table. #97590 (Sema Checherinda). - Change the default value of
mysql_datatypes_support_levelfrom empty todecimal,datetime64,date2Date32, enabling proper mapping of MySQLDATEtoDate32,DECIMAL/NUMERICtoDecimal, andDATETIME/TIMESTAMPwith precision toDateTime64by default. Previously, MySQLDATEcolumns were mapped toDatewhich cannot represent dates before 1970-01-01, causing data corruption. #97716 (Alexey Milovidov). - Accept array of part names instead of regexp for
mergeTreeAnalyzeIndexes{,UUID}since regexp is slow (Experimental feature). #98474 (Azat Khuzhin). - Change default
stderr_reactionfromthrowtolog_lastfor executable UDFs. UDFs that write warnings to stderr no longer fail when exit code is 0. Exit code exceptions now include stderr content. #99232 (Xu Jia).
New Feature
- Added bucketed serialization for Map columns in MergeTree (
map_serialization_version = 'with_buckets'). Keys are split into hash-based buckets so that reading a single key (m['key']) only reads one bucket instead of the entire column, providing 2-49x speedup for single-key lookups depending on map size. The number of buckets and the bucketing strategy can be controlled by new MergeTree settings:map_serialization_version,max_buckets_in_map,map_buckets_strategy,map_buckets_coefficient, andmap_buckets_min_avg_size. #99200 (Pavel Kruglov). - Support materialized CTE. Allow evaluating CTEs only once during query execution and store their results in temporary tables. Closes #53449. #94849 (Dmitry Novik).
- Allow certain SQL-standard functions without parentheses for compatibility, such as
NOW. Closes #52102. #95949 (Aly Kafoury). - You can now use the natural sort key function as
naturalSortKey(s). #90322 (Nazarii Piontko). - You can now use native JSON/Object input for JSONExtract functions. Closes #88370. #96711 (Fisnik Kastrati).
- If a query parameter has
Nullabletype and is not specified, we will assume that its value isNULL. #93869 (Vikash Kumar). - Support auxiliary ZooKeeper for
Replicateddatabase. #95590 (RinChanNOW). - Support
hasfunction for JSON type to check path existence, similar to Map. #96927 (DQ). - Added the
mergeTreeTextIndex(database, table, index)table function, which allows reading data directly from a text index. This function can be used for introspection or for performing aggregations on top of text index data. #97003 (Anton Popov). - Add
table_readonlyMergeTree setting to mark tables as read-only, preventing inserts and modifications. #97652 (Alexey Milovidov). - Add new setting
use_partition_pruningand aliasuse_partition_key. Set it tofalseto disable partition pruning based on the partition key. #97888 (Nihal Z. Miaji). - Implements
ALTER TABLE ... EXECUTE expire_snapshots('<timestamp>')for Iceberg tables. #97904 (murphy-4o). #99130 - Allow each
type=httpentry in<protocols>to specify a custom<handlers>key pointing to a separate<http_handlers_*>config section, enabling different HTTP routing rules per port. #98414 (Amos Bird). - Add
pretty=1option toEXPLAINfor tree-style indented output andcompact=1to collapseExpressionsteps, making query plans more readable. #98500 (Kirill Kopnev). - Add
restore_access_entities_with_current_grantsserver setting. When enabled, restored users/roles from backups have their grants limited to what the restoring user is allowed to grant (same semantics asGRANT CURRENT GRANTS), instead of failing withACCESS_DENIED. #98795 (pufit). - Add
caseFoldUTF8andremoveDiacriticsUTF8functions for Unicode case folding and diacritical mark removal. #98973 (George Larionov). - Add
normalizeUTF8NFKCCasefoldstring function for NFKC_Casefold Unicode normalization, which combines NFKC normalization with case folding. #99276 (George Larionov). - Add
asciiCJKtokenizer for full-text indexes and thetokensfunction. It splits text using Unicode word boundary rules: ASCII words are formed with connector characters (underscore, colon, dot, single quote), while non-ASCII Unicode characters become single-character tokens. #99357 (Amos Bird). - Added
max_skip_unavailable_shards_numandmax_skip_unavailable_shards_ratiosettings to limit how many shards can be silently skipped whenskip_unavailable_shardsis enabled. If the number or ratio of unavailable shards exceeds the configured threshold, an exception is thrown instead of returning silently incomplete results. #99369 (Alexey Milovidov). - Users can now use
SOMEkeyword for subquery expressions. It behaves identically toANY. #99842 (Artem Kytkin). - Add
output_format_trim_fixed_stringsetting to strip trailing null bytes fromFixedStringvalues in text output formats. #97558 (NeedmeFordev). - Support parenthesized table join expressions in FROM clause, e.g.
SELECT * FROM (t1 CROSS JOIN t2). #97650 (Alexey Milovidov). - Implement function
toDaysInMonth: it returns the number of days in the month of the specified date. #99227 (Vitaly Baranov).
Experimental Feature
- Add experimental support for WebAssembly-based user-defined functions (UDFs), allowing custom function logic to be implemented in WebAssembly and executed within ClickHouse. Special thanks to Alexey Smirnov for contributing the Wasmtime backend support. #88747 (Vladimir Cherkasov). Incremental improvements for WASM UDF support. #99373 (Vasily Chekalkin).
- Add support for external SQL dialects using
polyglotlibrary. #99496 (Alexey Milovidov). - Add
ALPfloating-point compression codec (without ALP_rd fallback for non-compressible doubles). #91362 (Nazarii Piontko). - Add experimental lazy type hints for
JSONcolumns. When enabled viaallow_experimental_json_lazy_type_hints,ALTER TABLE ... MODIFY COLUMN json JSON(path TypeName)that only adds or modifies type hints completes instantly as a metadata-only operation, without rewriting historical data. Type hints are applied at query time for old parts and materialized during INSERTs and background merges. #97412 (tanner-bruce). - Enable parallel reads from YTsaurus table engine. #97343 (MikhailBurdukov).
Performance Improvement
- Improve the performance of data lakes. In previous versions, reading from object storage didn't resize the pipeline to the number of processing threads. This gives orders of magnitude improvements (~40x) on multi-core machines. #99548 (Alexey Milovidov).
- Now, the relationship between
enable_parallel_replicasandautomatic_parallel_replicas_modeis as follows. A query can use parallel replicas only ifenable_parallel_replicas > 0. Additionally, ifautomatic_parallel_replicas_mode=1, the decision whether to use parallel replicas is made during planning based on the previously collected statistics. Ifautomatic_parallel_replicas_mode=0, parallel replicas will be used for all supported queries regardless of any statistics. One notable exemption is distributed insert-select with parallel replicas: in this case, queries will always be executed as ifautomatic_parallel_replicas_mode=0. #97517 (Nikita Taranov). - Allow partition pruning when the predicate contains any comparison operator (
=,<,>,!=) and the partition key is wrapped in a deterministic function chain (e.g.PARTITION BY xand predicates likecityHash64(x) % 5 > 2,toYYYYMM(x) < 2026,toYYYYMM(x) = 2026, ortoYYYYMM(x) != 2026will all use the partition key for pruning). Closes #28800. #98432 (Nihal Z. Miaji). - Allow read-in-order optimization and primary-key pruning when the
CASTtarget type isNullableand the conversion is monotonic; for example, withPRIMARY KEY x, ClickHouse can use read-in-order optimization forORDER BY x::Nullable(UInt64)and can apply primary-key pruning for predicates such asWHERE x::Nullable(UInt64) > 500000. #98482 (Nihal Z. Miaji). - Allow index pruning and filter pushdown when an integral column is compared with a float literal; for example, predicates like
WHERE x < 10.5can now use the primary key for pruning, and filters such asprime < 1e9ornumber < 1e5are now pushed down for theprimes()andnumbers()table functions instead of causing unbounded execution. Closes #85167. #98516 (Nihal Z. Miaji). - Added a new SLRU cache for Parquet metadata to improve read performance by removing the need to re-download files just to read metadata. #98140 (Grant Holly).
- Support swapping sides of ANTI, SEMI and FULL joins based on optimizer statistics. #97498 (Hechem Selmi).
- Optimize granules skipping for
pointInPolygonfor large polygons and fixpointInPolygonindex analysis throwing during primary key pruning. #91633 (Nihal Z. Miaji). - Improve performance of
levenshteinDistancefunction. #94543 (Joanna Hulboj). - Optimize batch decimal type conversions by avoiding per-element function calls. #95923 (Konstantin Bogdanov).
- Iceberg tables now support asynchronous metadata prefetching via
iceberg_metadata_async_prefetch_period_mstable setting, which periodically pre-populates the metadata cache. Additionally, theiceberg_metadata_staleness_msquery setting allows SELECT queries to use cached metadata if it is fresher than the specified staleness, eliminating calls to the Iceberg catalog during request processing. #96191 (Arsen Muk). S3Queueordered mode uses S3 ListObjectsV2 StartAfter to avoid re-listing full prefix history, reducing ListObjects calls. #96370 (Venkata Vineel ).- Lower memory usage for inserts deduplication. In general the original block is needed for deduplication, but for sync insert we could omit it and save the memory for good. #96661 (Sema Checherinda).
- Use an arch-specific value for cache line size instead of a hardcoded value of 64. #97357 (Nikita Taranov).
- Slightly optimized reading from the text index dictionary, improving the overall performance of text index analysis. #97519 (Anton Popov).
- Speed up
LZ4decompression of 16 byte blocks in ARM. #97774 (Raúl Marín). - Refactor tokenization to a new high-performance interface, replacing the old iterator-style API to support SIMD and stateful tokenizers. Part of #90268. #97871 (Amos Bird).
- Improved performance of text index analysis for queries with combined conditions involving both indexed and non-indexed columns. Previously, early exit optimization during index analysis was incorrectly disabled in such cases. #98096 (Anton Popov).
- Improve the performance of queries with constant expressions that generate very long arrays or maps. #98287 (Alexey Milovidov).
- Fix key condition analysis for
DateTime64primary keys compared with integer constants, which previously resulted in no granule pruning. #98410 (Amos Bird). - The setting
optimize_syntax_fuse_functionsis enabled by default. #98424 (Alexey Milovidov). - Optimize
avgWeightedaggregate function by using local accumulators instead of per-row store-forwarding through aggregate state, improving performance by up to 27% for Nullable inputs. #98793 (Antonio Andelic). - Improves performance and reduces memory usage for parallel window functions in certain scenarios, and for
arrayFoldworkloads with large arrays. This can also reduce page-fault pressure and improve stability under tight memory limits for affected queries. #98892 (filimonov). - Improve performance of sorted merges. #99013 (Artem Zuikov).
- Optimize
INTERSECT ALLandEXCEPT ALL. #99097 (Raufs Dunamalijevs). - Support the
read_in_order_use_virtual_rowoptimization for reverse-order reads. #99198 (Vladimir Cherkasov). - Reduce cache contention in
RIGHTandFULLJOINs by checking if JoinUsedFlags is set before writing. #99274 (Hechem Selmi). - Optimize
PrefetchingHelper::calcPrefetchLookAheadby replacing floating-point math with pure integer arithmetic, improving instruction cache layout and reducing cycle overhead during aggregation loops. #99327 (Riyane El Qoqui). - Reduce memory consumption of Keeper by replacing
absl::flat_hash_setwithCompactChildrenSetfor storing node children. The new container stores 0–1 children inline without heap allocation, which covers the majority of Keeper nodes. This reducesKeeperMemNodesize from 144 to 128 bytes. #99860 (Antonio Andelic). - Aggregate projections are now correctly supported in views. Fixes #32753. #88798 (Amos Bird).
- Support OUTER to INNER join conversion optimization with
join_use_nulls. Closes #90978. #95968 (Vladimir Cherkasov). - Improve subcolumns reading by correct sizes calculation before reading. It reduces memory usage and speeds up the subcolumns reading. #96251 (Pavel Kruglov).
- Make mark, uncompressed and page caches to use separate jemalloc arena to avoid memory fragmentation when short lived allocations, i.e., for queries and requests are mixed with longer lived allocations for caches. #96812 (Seva Potapov). #98812. #99021
- Tables with
DELETE TTLrules can now use the vertical merge algorithm. #97332 (murphy-4o). - Apply data skipping indexes during distributed index analysis. #97767 (Azat Khuzhin).
- Marks of secondary indexes are now prewarmed when the
prewarm_mark_cachesetting is enabled (loaded into the index mark cache during data part fetches and table startup). #97772 (Anton Popov). - Reduced locking during access control. #97894 (Nikita Taranov).
- When apply_row_policy_after_final or apply_prewhere_after_final is enabled, compound AND conditions in row policies and PREWHERE are now decomposed to extract sorting-key atoms for primary key index analysis. Previously, if a deferred filter contained a mix of sorting-key and non-sorting-key predicates (e.g. x > 1 AND y != 'foo'), the entire expression was excluded from index analysis. Now sorting-key atoms (like x > 1) are extracted and used for granule pruning, even from nested AND expressions. #98513 (Yarik Briukhovetskyi).
- Reduce lock contention in MergeTreeBackgroundExecutor by making task resources release without acquiring the lock. Closes #93620. #98604 (Dmitry Novik).
- Fix excessive memory usage (~514 MiB) during format auto-detection when reading non-Arrow data (e.g. JSON from
urlorfilewithout explicit format), caused by the ArrowStream reader misinterpreting the first bytes as a huge metadata length. #98893 (Konstantin Bogdanov).
Improvement
- Makes it possible to parse GeoParquet files that contain different Geo type in the same column. #97851 (Mark Needham).
- Introduce
tokensForLikePatternSQL function that tokenizes LIKE patterns while respecting wildcard semantics:%and_are treated as wildcards, escaped wildcards (\%,\_) are treated as literals, and tokens adjacent to unescaped wildcards are discarded. #97872 (Amos Bird). - Add a
{_schema_hash}placeholder for the S3 table engine that inserts a hash of the table's column definitions into the S3 path. #98265 (Miсhael Stetsyuk). SymbolIndex,addressToSymbol,system.symbols, andbuildIdnow work on macOS by parsing Mach-O symbol tables. #99014 (Alexey Milovidov).- The
system.stack_tracetable now works on macOS, allowing introspection of all server thread stack traces. #98982 (Alexey Milovidov). - Add per-server LDAP config option
<follow_referrals>(defaultfalse) to control whether the LDAP client follows referrals. Disabling referral chasing avoids timeouts and hangs when searching from an Active Directory domain-root base DN. Referral-related log messages are moved fromwarntotrace. #96765 (paf91). - We now track any data skipping indices that were used during query execution in the query_log table in a new column named
skip_indices. Fixes #78676. Original author @pheepa. #87862 (Grant Holly). - ACCESS_DENIED hints no longer reveal column names unless the user can show all required columns; database/table names remain visible in the hint. #91067 (filimonov).
- Add a dedicated cleanup thread for MergeTree to prevent cleanup delays under heavy merge load. This resolves #86181. #91574 (Amos Bird).
- Reload cluster config if IPs of local server’s hostname changed, instead of IPs of any host. Fixes #81215, #70156 and #65268. #93726 (Zhigao Hong).
- Allow optimize_aggregators_of_group_by_keys to correctly optimize aggregate functions in GROUPING SETS queries. #93935 (Xiaozhe Yu).
- Keeper-bench: report errors in metrics and generate json metrics file for --input-request-log mode. #95748 (Mohammad Lareb Zafar).
- Add new clause ROLE to CREATE USER. #97074 (Vitaly Baranov).
- You can now set internal_replication settings for a cluster created by the Replicated database. #97228 (Pervakov Grigorii).
- New setting
allow_nullable_tuple_in_extracted_subcolumnscontrols whether extractedTuple(...)subcolumns fromTuple,Variant,DynamicandJSONare returned asNullable(Tuple(...))(NULLfor missing rows) or asTuple(...)(default tuple values for missing rows). Disabled by default, this setting can only be changed by restarting the server. #97299 (Nihal Z. Miaji). - Add information about deferred filters as a separate item to EXPLAIN query output (when using Row Policies/PREWHERE with FINAL). Related: #91065. #97374 (Yarik Briukhovetskyi).
- Enable
type_json_allow_duplicated_key_with_literal_and_nested_objectby default. It allows to avoid errors about duplicated keys during parsing of JSONs like{"a" : 42, "a" : {"b" : 42}}that can be formatted by ClickHouse from original JSON data{"a" : 42, "a.b" : 42}. #97423 (Pavel Kruglov). - Keeper improvement:
find_super_nodesis a very useful command for debugging unexpected growth in the node count in Keeper. Unfortunately, if there are multiple super nodes, it's almost impossible to find more than one, because the command gets stuck forever traversing the children of the first encountered super node. This PR forbids traversing the children of super nodes. #97819 (pufit). - Initial completion support for
clickhouse-keeper-client. #97828 (Konstantin Bogdanov). - Flush async logging buffers in case of crash. #97836 (Azat Khuzhin).
- Enable the impersonate feature by default (see EXECUTE AS target_user). #97870 (Vitaly Baranov).
- Improve canceling queries with SQLite table engine by KILL QUERY and cancel query (Ctrl+C) in clickhouse-client. #97944 (Roman Vasin).
- Add server setting
jemalloc_profiler_sampling_rateto control jemalloc'slg_prof_sampleand expose it asjemalloc.prof.lg_sampleasynchronous metric. #97945 (Antonio Andelic). - Support weights in concurrent bounded queue implementation. #97962 (Daniil Ivanik).
- Add sslmode to the allowed keys for PostgreSQL dictionary sources. Previously, sslmode was not in the dictionary_allowed_keys allowlist in PostgreSQLDictionarySource.cpp, making it impossible to configure SSL mode for PostgreSQL dictionary connections. This prevented dictionaries from connecting to PostgreSQL servers that require SSL (e.g., AWS RDS, which enforces SSL by default), as the connection would fail TLS negotiation and the server would reject the unencrypted fallback. #98014 (mcalfin).
- Show a clear "no such file" error when passing a non-existent file path to
clickhouseorclickhouse-local, instead of a confusing generic message. #98048 (Raúl Marín). - Text indexes can now be built on top of
Nullable([Fixed]String)andArray(Nullable([Fixed]String))columns. #98118 (Jimmy Aguilar Mena). - Avoid dropping named collections that are dependencies of dictionary sources. #98127 (Pablo Marcos).
- Enable
grace_hashjoin algorithm for queries with totals. #98144 (János Benjamin Antal). - Cancel background merges early in DROP DATABASE for ordinary shared merge tree. #98161 (Shaohua Wang).
- Improve canceling queries with MongoDB and MySQL by KILL QUERY and cancel query (Ctrl+C) in clickhouse-client. #98187 (Roman Vasin).
- Remove NetlinkMetricsProvider and use procfs exclusively for per-thread taskstats metric collection. Netlink-based collection is problematic in containerized environments and has worse tail latency under contention. #98229 (Amos Bird).
- Refactor Iceberg manifest file handling to fix issues with manifest file caching. #98231 (Daniil Ivanik).
- Now we take into account cases where the sorting key of the table can be an expression like
toDate(time), and can make the decisions about not-deferring expressions like this if they are part of filters. #98237 (Yarik Briukhovetskyi). - Add a new
MaxAllocatedEphemeralLockSequentialNumbermetric for the maximum sequential number allocated for ephemeral lock znodes in ZooKeeper. #98243 (Miсhael Stetsyuk). - Update clickstack to version 2.20.0. #98252 (Aaron Knudtson).
- Added a new profile event
KeeperRequestTotalWithSubrequeststhat counts each subrequest within a multi-request individually, providing better visibility into the actual Keeper workload. The existingKeeperRequestTotalevent continues to count each multi-request as a single request. #98348 (Antonio Andelic). SYSTEM RELOAD DICTIONARIESnow reloads dictionaries in topological order so that dictionaries sourcing from other dictionaries see fresh data after reload. #98356 (Alexey Milovidov).- Restart the statistics cache after changing the MergeTree setting. #98520 (Han Fei).
- Only "alive" replicas (that are connectable) participate in distributed index analysis. #98521 (Azat Khuzhin).
- Add a setting
access_control_improvements.disallow_config_defined_profiles_for_sql_defined_users(disabled/allowed by default) that disallows using config-defined settings profiles (except for thedefaultprofile) for SQL-defined users. #98662 (Alexander Tokmakov). - Cap the number of nodes used in the automatic parallel replicas heuristic to the actual number of nodes in the cluster (instead of only the
max_parallel_replicassetting). #98668 (Nikita Taranov). - Implement hedged requests and asynchronous reading for distributed index analysis. #98724 (Azat Khuzhin).
- Deserialization of binary
AggregateFunctionstates now requires consuming the full input. If extra redundant trailing bytes are present, ClickHouse throws an exception instead of accepting malformed state data. #98786 (Nihal Z. Miaji). - Make TRUNCATE DATABASE respond to query cancellation. #98828 (Shaohua Wang).
- Improve
keeper-benchwith request pipelining, warmup period, per-operation stats, reproducible seeds, and better error handling. #98906 (Antonio Andelic). - Support SAMPLE clause in distributed index analysis. #98931 (Azat Khuzhin).
- Show chart title in dashboard even when query returns empty result or encounters an error. #98975 (Yash ).
- Analyzer error messages no longer dump all columns of a table (which could produce 150KB+ exceptions). Column lists are now capped at 10 entries. #99002 (Yash ).
- Properly return column stats from sub-queries with joins so that parent query can use them for join reordering. #99096 (Alexander Gololobov).
- Mark ZooKeeper session as expired immediately when finalization starts, instead of waiting for the send thread to exit. This allows other threads to establish a new session without delay. #99102 (Raúl Marín).
- Use more math functions from LLVM-libc:
exp,exp2,expm1,fabs,fabsl,floor,fmodl,log,log2,logf,pow,scalbn,scalbnl,copysignl,nan,nanf,nanl, and theexplogxfshared constants. #99118 (Konstantin Bogdanov). - Reduce memory usage and fix potential duplicate output in
system.jemalloc_profile_textcollapsed format. #99121 (Antonio Andelic). - Add
is_subrequestcolumn tosystem.aggregated_zookeeper_logto separate standalone requests from sub-requests inside Multi/MultiRead requests. Previously, sub-requests were aggregated into the same buckets as standalone requests, and since each sub-operation was logged with the total multi-request duration, the average latency became misleading. Sub-requests now have zero latency. #99169 (Miсhael Stetsyuk). - Allow
ALTER TABLE MODIFY COLUMN x TTL ...command without specifying column type. #99208 (Nikolay Degterinsky). - Skip stale Keeper requests for sessions that have already disconnected, avoiding unnecessary Raft round-trips. The number of tracked finished sessions is capped by the
max_finished_sessions_cache_sizecoordination setting. #99246 (Antonio Andelic). - Support text index built on
mapValues(map)withINoperator. #99286 (Anton Popov). - Shell-like completion support in clickhouse keeper-client (handle completions of arguments in quotes, i.e.
'foo ba', handle escaped arguments, i.e.foo\ ba, makelsprint quoted nodes, if they have whitespaces). #99312 (Azat Khuzhin). - Prevent Keeper
mntrcommand from getting stuck because of lock contention. #99472 (Antonio Andelic). - Reduce lock contention in Keeper dispatcher by invoking callbacks and dispatching read requests outside mutex scope, and add profiled lock guards for observability. #99751 (Antonio Andelic).
- Tolerate missing padding at the end of the last block of parquet files. #99857 (Seva Potapov).
Bug Fix (user-visible misbehavior in an official stable release)
- Fixes how an Alias table target is saved as a DDL dependency when not fully qualified: it's now saved with the Alias table database instead of the session database. #95175 (Enric Calabuig).
- Fix wrong result or exception during reading subcolumns of ALIAS columns. #95408 (Pavel Kruglov).
- Fix missing column when non-standard identifier alias in JOIN with old analyzer. Fixes #25594, #47288 and #53263. #95679 (Zhigao Hong).
- Fixes a crash in Kusto dialect functions
bin(),bin_at(),extract(), andindexof()when empty arguments are provided. #95736 (NeedmeFordev). - Forbids mounting local_object_storage (which is used by datalakes above local filesystem and maybe by LocalDisk) anywhere apart from user_files_path in clickhouse-client. #96201 (Daniil Ivanik).
- In
DeltaLaketable engine fix logical race on snapshot version change, remove redundant heavy snapshot reloads. #96226 (Kseniia Sumarokova). - Fix logical error on attaching a part in MergeTree if there were several chained renames between detaching and attaching. #96351 (Alexey Milovidov).
- Fix a bug where explicit settings sent alongside
compatibilityin the same request could be silently ignored when their value matched the server default. #97078 (Raufs Dunamalijevs). - Fix the client reporting
NETWORK_ERRORinstead of the actual parsing error (with the correct row number) when an INSERT with parallel parsing encounters invalid data. #97339 (Alexey Milovidov). - Fix
sumCountaggregate function not being able to read older serialized states after introduction ofNullable(Tuple). Closes #97370. #97502 (Nihal Z. Miaji). - Fix exception in tuple comparison involving
Nothingtype elements (e.g., comparing withNULLtuple elements) when used withGROUPING SETSandORDER BY. #97509 (Alexey Milovidov). - Fix non-deterministic
uncompressed_hashcomputation for Compact MergeTree parts when multiple compression codecs are used, which could cause incorrect deduplication behavior. #97522 (Alexey Milovidov). - Fix logical error about missing stream during INSERT SELECT with JSON and buckets in shared data. Closes #97331. #97523 (Pavel Kruglov).
- Fix
MEMORY_LIMIT_EXCEEDEDexceptions being incorrectly reported asCORRUPTED_DATAduring SummingMergeTree and CoalescingMergeTree merges. #97537 (János Benjamin Antal). - Fix "Context has expired" exception for correlated subqueries containing table functions like
url(). #97544 (Alexey Milovidov). - Fix exceptions and incorrect behavior in
optimize_syntax_fuse_functionswith aggregate projections, Date types, and column name preservation. #97545 (Alexey Milovidov). - Remove incorrect
replaceRegexpOnetoextractquery rewrite that produced wrong results when the regexp didn't match; also fix exception whenreplaceRegexpOneis used withGROUP BY ... WITH CUBEandgroup_by_use_nulls=1. #97546 (Alexey Milovidov). - Fix
DROP DATABASEwithdatabase_atomic_wait_for_drop_and_detach_synchronouslyhanging indefinitely when the query is killed. #97586 (Alexey Milovidov). - Fix
KILL QUERYnot being able to terminate queries stuck inWITH FILLgeneration, dictionary loading viadictGet, orALTER DELETEwithmutations_sync=1onReplicatedMergeTree. #97589 (Alexey Milovidov). - The
looptable function was callinginner_storage->read()directly, bypassing the interpreter layer where row policies, column-level grants, and other security checks are applied. This allowed a user restricted by row policies to read all rows vialoop(table)even when a direct SELECT returned zero rows. #97682 (pufit). - Fixes incorrect partition pruning in cases of using pre-epoch DateTime64 with
toDate()function. #97746 (Yarik Briukhovetskyi). - After this patch,
hasPartitionIdwill return false if another partition with a higher partition ID exists in the data part set. #97748 (Mikhail Artemenko). - Fix possible crashes during reading of empty granules in advanced shared data in JSON. Closes #97563. #97778 (Pavel Kruglov).
- Fix
Cannot schedule a fileLOGICAL_ERRORonINSERTintoDistributeddue to race betweenDROPandINSERT. #97822 (Azat Khuzhin). - Fixed ClickHouse server crash/assert in call to
mapContainsKey/mapContainsKeyLikewithtokenbf_v1skip index. #97826 (Shankar Iyer). - Fix LOGICAL_ERROR exceptions caused by
LowCardinalityinside compound types (Variant,Dynamic,Tuple) inconcatWithSeparator,format,INsubqueries,GLOBAL IN, and joins with runtime filters. #97831 (Raúl Marín). - Fix
LOGICAL_ERRORexceptionChunk info was not set for chunk in MergingAggregatedTransformwhen usingARRAY JOINwithmerge()table function over multiple Distributed tables combined withGROUP BY. #97838 (Raúl Marín). - Fix server crash (
std::terminate) caused by an uncaught exception in the HTTP connection pool destructor when the connection group hard limit is reached under high concurrency. The exceptionHTTP_CONNECTION_LIMIT_REACHEDcould escape~PooledConnectionwhen recycling a connection back to the pool, leading toSIGABRT. #97850 (Antonio Andelic). - Fix incorrect result when
grace_hashalgorithm is used with non-equi joins and left block cannot be processed completely because of the size constraints on the join result. #97866 (János Benjamin Antal). - Fix performance inefficiency in DeltaLake metadata scanning introduced in #96686. #97880 (Kseniia Sumarokova).
- Fix data race in ZooKeeper client between sendThread and receiveThread. #97887 (Pablo Marcos).
- Fixes a bug where it was not possible to use CTE with distributed insert selects. Continuation of https://github.com/ClickHouse/ClickHouse/pull/87789. Closes #95837. #97889 (Yarik Briukhovetskyi).
- Fix exception from
CachedOnDiskReadBufferFromFile::readBigAt. Closes #97325. #97890 (Kseniia Sumarokova). - Fix
LOGICAL_ERRORexception inAliasengine with materialized columns due to column mismatch. Closes #97907. #97921 (Kai Zhu). - Fix Keeper data loss after restart when using Azure Blob Storage with
s3_plainmetadata for log storage. #97987 (Antonio Andelic). - Fix JIT miscompilation of
signfunction for integer types wider thanInt8— values outside the -128..127 range could produce incorrect sign. #98012 (Alexey Milovidov). - Fixed
DUPLICATE_COLUMNexception and silent NULLs when reading Delta Lake tables that use column mapping "name" mode with struct fields whose names contain dots (e.g.STRUCT<`a.foo`: STRING, `b.foo`: STRING>). #98013 (Caio Ishizaka Costa). - Fix mutation after lightweight update and secondary indices. #98044 (Raúl Marín).
- Fix incorrect result of FINAL queries when mixing primary key and non primary key skip indexes. #98097 (Raúl Marín).
- Enforce READ ON FILE checks for scalar file() and DESCRIBE TABLE file(). #98115 (Nikolay Degterinsky).
- Fixes a crash where querying files with a glob pattern (e.g.,
file('dir/**', 'LineAsString')) would throw an unhandled filesystem exception (STD_EXCEPTION) if the directory contained a dangling symlink. Dangling symlinks are now silently skipped, and the query returns results from all valid files. #98143 (Mark Andreev). - Fix segfault in query plan optimization when converting outer join to inner join with
arrayJoinin filter expression. #98147 (Alexey Milovidov). - Fix
ProtobufListformat not working with Kafka engine due to read state not being reset between messages. #98151 (Alexey Milovidov). - Fix logical error with analyzer_compatibility_join_using_top_level_identifier and ARRAY JOIN, closes #98164. #98179 (Vladimir Cherkasov).
- Set
Watchcomponent for watch responses inaggregated_zookeeper_loginstead of leaving it empty. #98202 (Antonio Andelic). - If the partition key columns are not covered by the sorting key, then partition pruning could incorrectly skip partitions containing rows that should "win" during FINAL deduplication. #98242 (Yarik Briukhovetskyi).
- Fix logical error "Bad cast from type DB::ColumnConst to DB::ColumnArray" in
kql_array_sort_asc/kql_array_sort_descwhen called with constant array arguments. #98251 (Alexey Milovidov). - Fix out-of-bounds access in
ColumnConst::getExtremesthat could cause a crash whenextremes = 1is enabled. #98263 (Alexey Milovidov). - Fix potential deadlock when two concurrent
MOVE PARTITIONoperations work with the same pair of tables in opposite directions. #98264 (Alexey Milovidov). - HTTP server now returns an error message in the response body for 400 Bad Request responses caused by malformed headers, instead of an empty body. #98268 (Alexey Milovidov).
- Fix wrong results with distributed index analysis (experimental feature) and query condition cache. #98269 (Azat Khuzhin).
- Fixed LOGICAL_ERROR exception "Invalid binary search result in
MergeTreeSetIndex" triggered bytoDateconversion on key columns with data crossing the 65535 boundary. #98276 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception when a RIGHT JOIN wrapped in a CROSS JOIN is swapped by thequery_plan_join_swap_tableoptimization in the legacy join step code path. #98279 (Alexey Milovidov). - Validate corrupted data during
DDSketchdeserialization to prevent segfaults, exceptions, infinite loops, and OOM when reading corruptedquantilesDDaggregate function states. #98284 (Alexey Milovidov). - Fix LOGICAL_ERROR "Trying to execute PLACEHOLDER action" when correlated columns from outer queries are referenced inside lambda functions such as
arrayMap. #98285 (Alexey Milovidov). - Fix logical error exception in
caseWithExpressionwhenCASEexpression involvesmaterialize(NULL)or otherNullable(Nothing)arguments. #98290 (Alexey Milovidov). - Fix bad cast exception when filtering
_tablevirtual column inmergetable function. #98291 (Alexey Milovidov). - Fix sporadic deduplication failure where re-inserts were incorrectly deduplicated due to inconsistent cleanup ordering between
blocks/anddeduplication_hashes/ZooKeeper directories. #98293 (Alexey Milovidov). - Fix exception when
ORDER BY ... WITH FILLis used together withLIMIT BY. #98361 (Alexey Milovidov). - Fix silent data corruption when inserting a Parquet/Arrow
Datecolumn into anEnumcolumn — now properly rejects the incompatible type conversion instead of storing invalid enum values. #98364 (Alexey Milovidov). - Fix exception when reading an Arrow file with
Arraycolumn into a table withNestedcolumn. #98365 (Alexey Milovidov). - Fix
MATERIALIZE INDEXandMATERIALIZE PROJECTIONmutations getting stuck when the index or projection is dropped before the mutation finishes. #98369 (Alexey Milovidov). - Fix exception when reading from
Nullable(Tuple(...))where a Tuple element name collides with the Nullablenullsubcolumn. #98372 (Alexey Milovidov). - Fix exception "Column ... query tree node does not have valid source node" when joining a
Mergetable (wrapping aDistributedtable) with another table. #98376 (Alexey Milovidov). - Fix incorrect Parquet
BooltoFixedStringconversion in native V3 reader that produced raw bytes instead of string representation. #98378 (Alexey Milovidov). - Fix
tryGetColumnDescriptionto filter subcolumns by parent column kind, consistent with other column lookup methods. #98391 (Alexey Milovidov). - Accept base64 credentials without padding in HTTP Basic Auth. Some HTTP clients omit trailing
=padding in theAuthorization: Basicheader, which previously caused authentication failures. #98392 (Amos Bird). - Fix incorrect partition pruning results after merging parts with
Nullablepartition key columns, caused by wrong min-max index bounds. #98405 (Amos Bird). - Fix rare exception in the pipeline executor, that could manifest as a
Received signal 6(only in debug builds), when pipeline expansion races with query cancellation. #98428 (Alexey Milovidov). - Fix exception "Column identifier is already registered" when
count_distinct_optimizationis used with aQUALIFYclause. #98433 (Alexey Milovidov). - Fix exception "cannot be inside Nullable type" when using
IN/NOT INwithLowCardinalitycolumn arguments (e.g.a NOT IN (b)whereaisLowCardinality(String)). #98443 (Alexey Milovidov). - Fix "Pipeline stuck" exception in
full_sorting_mergejoins caused by a deadlock inPingPongProcessorwhen theFilterBySetOnTheFlyoptimization created a circular dependency withMergeJoinTransform. #98454 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception "Projection cannot increase the number of rows in a block" when merging parts with TTL that deletes all rows and an aggregate projection with a constantGROUP BYkey. #98458 (Alexey Milovidov). - Fix logical error exception when
CROSS JOINis used together withINNER JOIN USING. #98459 (Alexey Milovidov). - Fix null pointer dereference in
dictGetOrDefaultwhen the key argument isNullable. #98460 (Alexey Milovidov). - Fix exception in
DISTINCTqueries when using aggregate projections andmaterializecausesLowCardinalitytype differences between the query and the projection. #98462 (Alexey Milovidov). - Fix LOGICAL_ERROR exception when
arrayJoinis used in a filter expression with OUTER JOIN andjoin_use_nullsenabled. #98464 (Alexey Milovidov). - Fix logical error exception "Replica decided to read in WithOrder mode, not in ReverseOrder" when using parallel replicas with
optimize_aggregation_in_order. #98467 (Alexey Milovidov). - Fixed ClickHouse Keeper disconnecting Java ZooKeeper clients after
addWatchrequest. The Java client expects a 4-byteErrorResponsebody in theaddWatchresponse, but Keeper was sending an empty body, causingEOFExceptionand session disconnect. This broke Apache Curator'sCuratorCacheand any Java application using persistent watches. Fixes #98079. #98499 (Antonio Andelic). - Fix
zk_followersandzk_synced_followersKeeper metrics not decreasing when a follower goes down. Add newzk_learnersandzk_synced_non_voting_followersmetrics to themntrfour-letter-word command. Fixes #54173. #98504 (Antonio Andelic). - Fix a LOGICAL_ERROR exception in
renameAndCommitEmptyPartsthat could occur whenTRUNCATE TABLEruns concurrently withOPTIMIZE TABLEusing MergeTree transactions. #98508 (Alexey Milovidov). - Fixed Keeper's secure raft port ignoring
cipherListanddhParamsFilefromopenSSLconfiguration, always using defaults instead of user-specified values. Close #51188. #98509 (Antonio Andelic). - Fixed misleading Keeper log messages like "Receiving request for session X took 9963 ms" where the reported time was actually spent waiting idle in
poll()between heartbeats, not performing the operation itself. Fixes #79026. #98510 (Antonio Andelic). - Fix unexpected result with read_in_order_use_virtual_row and monotonic functions, close #97837. #98514 (Vladimir Cherkasov).
- Fix
LOGICAL_ERROR: Not-ready Set is passed as the second argument for function 'in'when usingPREWHEREwithINsubquery on MergeTree tables. #98522 (Alexey Milovidov). - Fix Keeper TCP connections preventing graceful server shutdown by not responding to shutdown signal. #98525 (Alexey Milovidov).
- Fix exception "Sorting column wasn't found in the ActionsDAG's outputs" when
query_plan_convert_join_to_inis enabled withquery_plan_merge_expressions = 0. #98526 (Alexey Milovidov). - Fix MongoDB dictionary source failing with named collections. Closes #97840. #98528 (Pablo Marcos).
- Fixed LOGICAL_ERROR when Identifier is empty after parameter substitution. #98530 (Pervakov Grigorii).
- Fix pipeline deadlock when using
sort_overflow_mode = 'break'together with window functions. #98543 (Alexey Milovidov). - Fix column rollback in Buffer engine during handling an exception during appending a new block. Old logic could lead to corrupted in-memory state of columns. #98551 (Pavel Kruglov).
- Fixed exception
Bad cast from type ColumnConst to ColumnDynamicin null-safe comparison (<=>/IS NOT DISTINCT FROM) with constDynamicorVariantcolumns andNULL. Also fixedIS DISTINCT FROMwithDynamic/VariantvsNULLalways incorrectly returning 0. #98553 (Alexey Milovidov). - Fixed usage of the text index with other skip indexes. Previously, logical errors such as "Trying to get non-existing mark" could be thrown when a query filter utilized a text index and other regular skip indexes simultaneously. #98555 (Anton Popov).
- Fix logical error "TABLE_FUNCTION is not allowed in expression context" when a table function with an alias appears multiple times in the same query scope (e.g. in both
PREWHEREandQUALIFYclauses). #98557 (Alexey Milovidov). - Fix distributed index analysis with expressions (not just columns) in PK (leads to zero filtering of redundant granules on remote replicas). #98561 (Azat Khuzhin).
- Disallow dropping column when its subcolumns are used in other columns default/alias expressions and use analyzer for default expressions on alter drop column. #98569 (Nikita Mikhaylov).
- Fix S3 requests being incorrectly retried on non-retryable errors (including
HTTP_CONNECTION_LIMIT_REACHED) in the HTTP client. #98598 (Sema Checherinda). - Fixes a decimal overflow when partition pruning with DateTime64. #98628 (Yarik Briukhovetskyi).
- Fix two bugs in JIT expression compilation: a copy-paste error in
nativeCasttype checking that made integer-to-integer and float-to-float cast branches unreachable, and incorrectnullptrTargetMachine passed to LLVMPassBuilderpreventing target-specific optimization passes from being registered. #98660 (Alexey Milovidov). - Fix RBAC bypass that allowed users to DESCRIBE any table via
remote(),remoteSecure(),cluster(), orclusterAllReplicas()pointed at localhost, without requiringSHOW_COLUMNSprivilege. #98669 (pufit). - Fix
BAD_GETexception and incorrect query results when a non-boolean expression (e.g.sin(col)) is used in both WHERE and SELECT with a JOIN, due to filter push-down optimization corrupting shared DAG nodes. #98681 (Alexey Milovidov). - Fix LOGICAL_ERROR "Replica decided to read in Default mode, not in WithOrder" when using
read_in_order_through_joinwith parallel replicas. #98685 (Alexey Milovidov). - Fix exception "Bad cast from type
DB::TableFunctionNodetoDB::QueryNode" when usinginputtable function as an argument ofremote. #98694 (Alexey Milovidov). - Fix outdated data parts resurrection caused by incorrectly cleaning up empty covering parts. #98698 (Shaohua Wang).
- Fix exception in
LogicalExpressionOptimizerPasswhen a boolean function in anequalscomparison returns aVarianttype. #98712 (Alexey Milovidov). - Fix
parseDateTimeBestEffortincorrectly parsing words starting with month/weekday prefixes. Closes #97965. #98742 (Pavel Kruglov). - Fix
UNKNOWN_IDENTIFIERexception when queryingmerge()table function orMergeengine over tables with JSON columns that have different parameters (e.g. differentSKIPfields) and ALIAS columns referencing JSON sub-paths, with the new analyzer enabled. Closes #97812. #98753 (Pavel Kruglov). - Fix
optimize_skip_unused_shardsoptimization with the analyzer in caseDistributedstorage is used in aView. #98754 (Nikolai Kochetov). - Fix tuple subcolumn access by name (e.g.
SELECT x.aforTuple(a UUID, b Int32)) for external tables passed via--externalinclickhouse-client. Closes #96925. #98755 (Pavel Kruglov). - Fix
reverseUTF8exception on invalid (truncated) UTF-8 input. #98770 (Alexey Milovidov). - Fix detecting set skip index usefulness with OR with false (i.e. or(x, 0)) predicate. #98776 (Azat Khuzhin).
- Fix a
LOGICAL_ERRORexception (Block structure mismatch inremoveUnusedColumns) that could occur withFINAL+PREWHERE+ constantWHEREexpression + column-independent aggregates likecount(). #98778 (Alexey Milovidov). - Make
system.trace_logentries for ClickHouse dictionaries' auto-reloads have non-empty query IDs. #98784 (Miсhael Stetsyuk). - Fixes a crash where we could de-reference a null pointer in system tables created between the time when we snapshot the tables in the
IDatabaseTablesIterator::table()call and the tables changing in another thread during later iteration. #98792 (Grant Holly). - Fix
SYSTEM START REPLICATED VIEWnot waking up the refresh task. #98797 (Pablo Marcos). - Fix exception "Inconsistent table names" when using
view()table function containing JOINs inside another JOIN (only with old analyzer). #98809 (Alexey Milovidov). - Fix adjusting RLIMIT_SIGPENDING (via pending_signals). #98829 (Azat Khuzhin).
- Fix exception when composing
loopwith cluster table functions. #98860 (Konstantin Bogdanov). - LEFT ANTI JOIN with multiple join key columns returned wrong results when
enable_join_runtime_filters=1(which is default). #98871 (Alexander Gololobov). - Fix
WITH FILL STALENESSproducing extra filled rows when data is read in multiple chunks (e.g., with smallindex_granularity). #98895 (Alexey Milovidov). - Fix "RPNBuilderFunctionTreeNode has A arguments, attempted to get argument at index B" LOGICAL_ERROR. #98900 (Azat Khuzhin).
- Fix memory tracking drift caused by failed allocations not being rolled back,
nallocx(0)undefined behavior, and off-by-one in global peak tracking. Extend tracking to coverio_uringring buffers. #98915 (Antonio Andelic). - Forbid attaching to local data lake tables outside user paths, not only creating them. #98936 (Daniil Ivanik).
- Fix a race condition that could cause a "ReadBuffer is canceled" exception in queries using
urlClusteror similar cluster table functions. #98955 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception in financial functions (financialNetPresentValue,financialInternalRateOfReturn, etc.) whenBFloat16type arguments are passed. #98958 (Alexey Milovidov). - Fix skip indexes (and primary key conditions) not being applied for ALIAS columns when query plan expression merging is disabled (query_plan_merge_expressions = 0 or query_plan_enable_optimizations = 0). #98960 (Peng).
- Increment
InsertQueryProfileEvent for async inserts. Closes #98626. #98962 (Narasimha Pakeer). - Fix exception "Inconsistent KeyCondition behavior" in debug builds when primary key contains NaN float values, by making
accurateLessandaccurateEqualshandle NaN consistently with ClickHouse sort order. Closes #98075. #98964 (Alexey Milovidov). - SummingMergeTree no longer sums Bool (and other domain type) columns. Bool values are kept as-is instead of being arithmetically summed. #98976 (Yash ).
- Fixes an exception Scalar doesn't exist that occurred when querying a remote shard with
optimize_const_name_sizeset andenable_scalar_subquery_optimization= 0. Large constants replaced with__getScalarreferences in the remote query were not being sent to the shard, causing the query to fail. #98979 (andriibeee). - Fix
NOT_FOUND_COLUMN_IN_BLOCKfor some queries withGROUP BYand expressions that include inverse dictionary lookup,Date/DateTimeconversion comparisons, and tuple comparisons. Closes #98888. #98980 (Nihal Z. Miaji). - Fixed undefined behavior (null pointer dereference) when altering a version/sign/is_deleted column to
EPHEMERALorALIASin MergeTree engines. Such alterations are now properly rejected. #98985 (Alexey Milovidov). - Fixed an issue where
system.grantsomitted the regular expression parameters forURLandS3grants in theaccess_objectcolumn. #98987 (DQ). - Fixed Iceberg BigLake reads: ADC credentials are now forwarded to the GCS S3 client (fixing 403 errors), OAuth2 credentials are URL-encoded before sending (fixing auth failures for tokens with special characters), and namespace traversal no longer aborts on BigLake HTTP 400 responses. #98998 (Nikita Fomichev).
- Fixed
clickhouse-clientfailing to switch timezone whenTZenvironment variable uses POSIX file path syntax (e.g.TZ=:/etc/localtime). #99000 (Yash ). - Fix incorrect or less pruning when
startsWith,LIKE,NOT LIKEused withFixedStringcolumn. Additionally,FixedStringtoStringcast function can now prune granules when wrapped around key column. Closes #98940. #99001 (Nihal Z. Miaji). - Fixed
windowFunnelwithstrict_deduplicationreturning incorrect level when a duplicate event was encountered. #99003 (Yash ). - Fixes a bug where EXISTS would ignore LIMIT and OFFSET clauses in subqueries, causing incorrect results when the subquery returned no rows due to an offset or a zero limit. Closes #88722. #99005 (andriibeee).
- Fix "Block structure mismatch" exception when filter push-down optimization encounters an AND expression that short-circuits to a constant with
GROUPING SETS. #99010 (Alexey Milovidov). - Fix exception when reading patch parts (lightweight updates) without
_part_offsetcolumn in the query plan. #99023 (Alexey Milovidov). - A query like
SELECT * FROM table WHERE pk_id = ''wherepk_idis the primary key and ofStringtype will now correctly use the primary key index for filtering granules. #99027 (Shankar Iyer). - Fix
DEPENDENCIES_NOT_FOUNDexception in Kafka engine when materialized view is detached while the background thread is streaming data. #99028 (Alexey Milovidov). - Fix exception when creating a table with an
EPHEMERALcolumn that has the same name as a virtual column (e.g.,_part_offset). #99031 (Alexey Milovidov). - Fix misleading "inflate failed: buffer error" when reading non-existent compressed files via
url()table function with glob patterns. Now returns empty result as expected whenhttp_skip_not_found_url_for_globsis enabled. #99034 (Alexey Milovidov). - Fix server crash (std::terminate) when executing
ALTER TABLE ... DROP PARTon a patch part after a schema change (e.g. ADD COLUMN). The crash was caused by missing system columns (_part) in the empty coverage part metadata, leading to an uncaught exception inside a NOEXCEPT_SCOPE. #99036 (Peng). - ClickHouse server process could crash if there was a memory limit exceeded exception thrown during a cached disk read. That is now fixed. #99042 (Shankar Iyer).
- Fix
LOGICAL_ERRORwhen querying a table that has both a ROW POLICY and an ALIAS column usingdictGet. The issue was caused by premature access to the table expression during ALIAS column resolution in the new analyzer. #99065 (Peng). - Fix out of bounds error when user tries to query only virtual columns from Iceberg table with Avro format for data. It's super rare scenario so not marking it as critical. Fixes #88238. #99080 (alesapin).
- Fix segfault in recursive CTE with
remote()+view(). #99081 (Konstantin Bogdanov). - Skip unnecessary extra index analysis when read-in-order optimization is applied. #99084 (Vladimir Cherkasov).
- Fixed a crash triggered by a memory limit exception thrown during patch part application. #99086 (Anton Popov).
- Fix debug assertion in
DDLWorkercaused by stalefirst_failed_task_nameafter a ZooKeeper entry is deleted during reinitialization recovery. #99099 (Antonio Andelic). - Fixed rebuild of text indexes on merges with TTL. #99107 (Anton Popov).
- Fix crash in
ALTER TABLE ... REMOVE SETTINGSquery for Iceberg table engine. Fixes #86330. #99108 (alesapin). - Fixes a bug in
query_plan_convert_any_join_to_semi_or_anti_joinoptimization, returning an incorrect result for unmatched rows. Related: https://github.com/ClickHouse/ClickHouse/pull/95995. #99112 (Yarik Briukhovetskyi). - Fix LOGICAL_ERROR exception in
ASTColumnsExceptTransformer::transform. #99119 (Pablo Marcos). - Fix RBAC bypass that allowed users to obtain table structure via
DESCRIBE TABLEorCREATE TABLE ASon table functions (mysql(),postgresql(),sqlite(),arrowFlight(),jdbc(),odbc(), etc.) without the required source access privileges. For functions that infer schema from remote servers, this also allowed triggering outbound connections (SSRF) without authorization. #99122 (pufit). - Fix Keeper crash (segfault in NuRaft) during dynamic reconfiguration and leadership transfer. #99133 (JIaQi Tang).
- Fix crash on usage of Buffer table with SAMPLE when destination does not support it. #99141 (Kseniia Sumarokova).
- Fix LOGICAL_ERROR due to patch parts column order mismatch. #99164 (Pablo Marcos).
- Fix very rare crash when Iceberg table contains files of mixed format (ORC and Parquet). Fixes #88126. #99168 (alesapin).
- Fix max_execution_time not being applied for backup/restore. #99205 (Kseniia Sumarokova).
- Fix
insert_deduplication_tokenbeing silently ignored forINSERT SELECTqueries withoutORDER BY ALL. Previously, deduplication was disabled entirely for unsortedINSERT SELECT, even when an explicit user token was provided. Now, providinginsert_deduplication_tokenis sufficient to enable deduplication regardless ofORDER BY ALL. #99206 (Desel72). - Fix excessive access checks during
InverseDictionaryLookupPassoptimization by checkingCREATE_TEMPORARY_TABLEgrant once before the pass instead of for every visited node. #99210 (Mikhail Artemenko). - Fix
clickhouse format --obfuscateproducing invalid SQL by obfuscating skip index types, compression codec names, database engine names, and dictionary layout/source definitions. #99260 (Raúl Marín). - Fixed a bug where, in some cases, comparing between Time[64] and DateTime[64] types was confusing; now, in cases like this, Time[64] values are promoted to DateTime[64] by adding the
1970-01-01as a date part. #99267 (Yarik Briukhovetskyi). - Clamp settings constraints in DDL worker for distributed DDL queries. #99317 (Pablo Marcos).
- Fix minor issues with TOTP authentication: the
--one-time-passwordCLI option with empty password, validation of<digits>and<period>configuration values. #99322 (Vladimir Cherkasov). - Fix logical error
unordered_map::at: key not foundin Avro output format when serializingEnum8/Enum16columns with values not present in the enum definition. #99332 (Desel72). - Fix CHECK TABLE with sparse serialization inside Tuple with Dynamic. Closes #96588. #99351 (Pavel Kruglov).
- Fixed too strict validation of text index preprocessor. #99359 (Anton Popov).
- Fix compatibility when upgrading replicated tables with implicit minmax indices from 25.10 to newer versions. #99392 (Raúl Marín).
- Removed support for negated functions (
notEquals,notLike,notIn) in text index analysis. These functions could never skip any granules, so analyzing the index for them only added overhead without any benefit. #99393 (Anton Popov). - Fix
optimize_skip_unused_shardswith a new analyzer for the case when aDistributedtable was used inside an IN subquery. #99436 (Nikolai Kochetov). - Fix heap-use-after-free in
INTERSECT/EXCEPTwhen the query produces duplicate column names. #99471 (Alexey Milovidov). - Fix logical error in
ALTER TABLE ... DROP PARTwhen a typed query parameter is used for the part name. #99489 (Alexey Milovidov). - Fixed
NOT_FOUND_COLUMN_IN_BLOCKexception when a text index predicate (e.g.hasAllTokens) is referenced in bothSELECTandWHEREclauses via an alias. #99504 (Anton Popov). - Fix incorrect results when using
hasAllTokenswith OR across columns that have separate text indexes. #99505 (Anton Popov). - Initialize page cache in
clickhouse-localso thatpage_cache_max_sizesetting takes effect. #99510 (Alexey Milovidov). - Fixed rare incorrect marking of a data part as broken and detaching it after
DETACH/ATTACH TABLEquery. #99529 (Anton Popov). - Fix
std::length_errorexception when querying empty system tables with Pretty format via HTTP interface. #99541 (Alexey Milovidov). - Fix
LOGICAL_ERRORwhen usingALTER TABLE ADD COLUMNto create anEPHEMERALcolumn with the same name as a virtual column (e.g._part_offset). #99549 (Alexey Milovidov). - Fix
VectorSimilarityIndexCacheentries never being evicted after part removal due to mismatched cache keys. #99575 (Seva Potapov). - Forbid reading Google credentials from a local file. This setting is insecure because it allows reading other credentials if the file path is known. #99584 (Konstantin Vedernikov).
- Fix performance degradation in the analyzer. Prune unused columns from ARRAY JOIN. #99587 (Dmitry Novik).
- Fixed reading of text index in table with existing lightweight deletes and row policies. #99661 (Anton Popov).
- Fix nullptr dereference in Parquet reader when filter-in-decoder path encounters filtered-out pages. Closes #99676. #99677 (Alexey Milovidov).
- Fix incorrect seek in AsynchronousReadBufferFromFileDescriptor with O_DIRECT. Closes #99358. #99678 (Pavel Kruglov).
- Fixed heap-buffer-overflow in
CompressionCodecT64and process abort inCompressionCodecMultiplewhen decompressing malformed compressed data. Both issues were found by new libFuzzer targets. The codecs now throw an exception instead of crashing. #99680 (Rahul). - Delay processing until server has finished loading all the tables. #99700 (Seva Potapov).
- Fix MySQL dictionary source bypassing
RemoteHostFilterfor inline DDL params. #99720 (Shaohua Wang). - Fix logical error when iterating over data lake tables in
system.tables. #99739 (Konstantin Vedernikov). - Fixed analysis of predicates with the
INfunction by text index with the preprocessor. Fixed the collision of searched tokens in the text index, which could lead to incorrect results. #99755 (Anton Popov). - Fix infinite loop when reading
Npyformat files with negative shape dimensions. #99812 (Desel72). - Fix global-buffer-overflow in
CRC32function onFixedStringarguments when evaluated with zero rows during query plan header computation. #99835 (Alexey Milovidov). - Fix crash (null pointer dereference) when executing
ALTER TABLE ... MODIFY COLUMN ... COMMENTon Iceberg tables. #99838 (Desel72). - Fix
aggregate_functions_null_for_emptysetting to work with aggregate functions returning non-Nullable types such asArrayorMap(e.g.,groupArray,sumMap). #99839 (Alexey Milovidov). - Fix LOGICAL_ERROR exception in
midpointfunction when called with mixed signed/unsigned integer types. #99867 (Alexey Milovidov). - Fix "Block structure mismatch" exception in queries with HAVING clause where the filter expression contains both an aggregate wrapped in a NULL-producing function and
materialize(0). #99915 (Alexey Milovidov). - Fix assertion failure in
sipHash128Keyed(and similar keyed hash functions) when the data argument is a Map with array keys or other nested array types. #99921 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception "Not-ready Set" inINfunction during query plan optimization withconvertAnyJoinToSemiOrAntiJoin. #99939 (Alexey Milovidov).
Build/Testing/Packaging Improvement
- Reduce compilation time by removing heavy header includes and moving expensive template instantiations out of headers. #97893 (Raúl Marín).
- Reduce compile time of arithmetic functions and related headers by shrinking template dispatch matrices and removing heavy includes. #98204 (Raúl Marín).
- Use
mongo-c-driver2.2.2. #98304 (Konstantin Bogdanov). - Use
postgresREL_18_3. #98306 (Konstantin Bogdanov). - Enable jemalloc allocator for UBSan builds to avoid RSS accumulation from glibc malloc's poor memory reclamation behavior. #98444 (Alexey Milovidov).
- Use Rust v0 symbol mangling and strip internal symbols from PRQL library to reduce symbol name bloat from parser combinator libraries. #98446 (Alexey Milovidov).
- Add TPC-H benchmark suite and TPC-DS README to
tests/benchmarks. #98495 (Raufs Dunamalijevs). - Add correctness tests for all 99 TPC-DS queries. #99204 (Raufs Dunamalijevs).
- Add integration test reproducing DDL CREATE TABLE + ALTER with offline replica bug (#44070), marked as expected failure. #99259 (Raufs Dunamalijevs).
- Integrate jemalloc with
je_prefix and remove usage of linker's --wrap. #99342 (Azat Khuzhin).
ClickHouse release 26.2, 2026-02-26. Presentation, Video
Backward Incompatible Change
- Deduplication is turned ON for all inserts by default. It was OFF before for async inserts and for MV's, but it was ON for sync inserts. The goal is to have the same defaults for both ways of inserts. If you have deduplication explicitly disabled on your cluster, you have to explicitly set
deduplicate_insert='backward_compatible_choice'to keep the old behavior. The same withdeduplicate_blocks_in_dependent_materialized_views. #95970 (Sema Checherinda). - Improved storage format of statistics. All statistics are now stored in a single file. #93414 (Anton Popov). If you didn't explicitly enable table statistics, you can ignore this item.
- Limit S3(Azure)Queue in-memory metadata. System tables are renamed from
azure_queuetoazure_queue_metadata_cacheandsystem.s3queuetos3queue_metadata_cache. #95809 (Kseniia Sumarokova). - Previously, applying a function to a
Variantcolumn silently returned NULLs when a variant sub-type was incompatible with the function; now it throws an exception, which may break queries that relied on the silent NULL behavior. #95811 (Bharat Nallan). DATEcolumns from PostgreSQL are now inferred asDate32in ClickHouse (in previous versions they were inferred asDate, which led to overflow of the values outside of a narrow range). Allow insertingDate32values back to PostgreSQL. Closes #73084. #95999 (Alexey Milovidov).- The semantics of the
do_not_merge_across_partitions_select_finalsetting were made more obvious. Previously, the feature could be automatically enabled when the setting was not explicitly set in the configs. It caused confusion repeatedly and, unfortunately, led to some issues in production. Now, the rules are simpler:do_not_merge_across_partitions_select_final=1enables the functionality unconditionally. Ifdo_not_merge_across_partitions_select_final=0, then automatic is used only if the new settingenable_automatic_decision_for_merging_across_partitions_for_final=1and not used otherwise. To preserve the old behaviour as much as possible, the defaults were set todo_not_merge_across_partitions_select_final=0andenable_automatic_decision_for_merging_across_partitions_for_final=1. #96110 (Nikita Taranov). - When creating an S3 table with explicitly specified columns, ClickHouse now validates that those column names actually exist in the remote file's schema. Queries that previously worked with mismatched column names will now fail at table creation time. This closes #96089. #96194 (Konstantin Vedernikov).
- Forbid using subqueries in ORDER BY and other table key expressions. #96847 (Alexey Milovidov).
- Enable
apply_row_policy_after_finalby default. Initially, whenoptimize_move_to_prewhere_if_final=0, both ROW POLICY and PREWHERE respect FINAL and were applied after FINAL. This was broken by #87303, which ignored theoptimize_move_to_prewhere_if_finalfor the ROW POLICY filter. To fix this, this PR enables the settingapply_row_policy_after_finalintroduced in #91065. Withapply_row_policy_after_finalenabled, ROW POLICY would continue to respect FINAL by default, as previously. This PR is an incompatible change because it changes the behaviour foroptimize_move_to_prewhere_if_final=1. Now, to get the ROW POLICY applied before FINAL,apply_row_policy_after_finalshould be used instead ofoptimize_move_to_prewhere_if_final. #97279 (Nikolai Kochetov). - The
Datetype is now serialized as Arrow's nativedate32type in Arrow/ArrowStream formats, instead ofuint16. Tools like PyArrow will now correctly see the column as a date type. The old behavior can be restored with theoutput_format_arrow_date_as_uint16setting. Reading old Arrow files that useduint16forDatecolumns is still supported. #96860 (Alexey Milovidov).
New Feature
- Users can now use ClickStack (an observability UI) directly from ClickHouse, useful for debugging and local development. #96597 (Aaron Knudtson).
- Support time-based one-time password (TOTP) as an authentication method. #71273 (Vladimir Cherkasov).
- Add
lazy_load_tablesdatabase setting. When enabled, tables are not loaded during database startup — a lightweightStorageTableProxyis created instead and the real table engine is materialized on first access. #96283 (xiaohuanlin). - Added
input_format_max_block_wait_mssetting to emit data blocks by timeout and allowed processing of remaining data when an HTTP connection is closed unexpectedly. #94509 (Mostafa Mohamed Salah). - Google BigLake catalog integration. This closes #95339. #97104 (Konstantin Vedernikov).
- Added system table
system.tokenizerswhich shows all available tokenizers. #96753 (Robert Schulze). - Add new system table
system.user_defined_functionsto monitor UDF loading status and configuration. #90340 (Xu Jia). - Add
system.jemalloc_statstable exposing jemalloc memory allocator statistics (viamalloc_stats_print) for diagnosing memory usage on servers built with jemalloc. Also add a/jemalloc.htmlHTTP endpoint on the ClickHouse HTTP interface for interactive visualization of these statistics. #97077 (Antonio Andelic). - Added
system.jemalloc_profile_texttable for reading and analyzing jemalloc heap profiles. The output format is controlled by thejemalloc_profile_text_output_formatsetting (raw, symbolized, or collapsed; default collapsed). Inline frame resolution is controlled byjemalloc_profile_text_symbolize_with_inline(when enabled, inline frames are included at the cost of slower symbolization; when disabled, they are skipped for faster output). For the collapsed format,jemalloc_profile_text_collapsed_use_countcontrols whether stacks are weighted by live allocation count (true) or live bytes (false, default). This enables easier memory profiling and flame graph visualization of jemalloc heap profiles. Fixes #93248. #97218 (Antonio Andelic). - Add the
default_dictionary_databasesetting, which lets ClickHouse resolve external dictionaries referenced without a database qualifier in a specified default database. This simplifies migration from XML-defined global dictionaries to SQL-defined per-database dictionaries—allowing existing dictionary queries (e.g. dictGet('name', …)) to continue working without modification. #91412 (Dmitrii Plotnikov). - Support auxiliary zookeeper for
DatabaseReplicated. #91683 (RinChanNOW). - Implement new table function
primesand new system tablesystem.primesthat contains prime numbers in ascending order. Closes #90839. #92776 (Nihal Z. Miaji). - Async inserts support parallel quorum. The inserted data is replicated to the quorum. If duplicates are found, query waits until previously inserted data is replicated as well. #93356 (Sema Checherinda).
- Added functions
colorOKLABToSRGB,colorSRGBToOKLABto convert value from sRGB to OKLAB and vice versa. #93361 (Pranav Tiwari). - A new
deduplicate_insertsetting which overridesinsert_deduplicateandasync_insert_deduplicate. #94413 (Sema Checherinda). - Server setting
insert_deduplication_versionmakes it possible to migrate on unified deduplication hash. #95409 (Sema Checherinda). - Add
xxh3_128hashing function. #96055 (Raúl Marín). - Added
OPTIMIZE <table> DRY RUN PARTS <part names>query to simulate merges without committing the result part. It may be useful for testing purposes: verifying merge correctness in the new version, deterministically reproducing merge-related bugs, and reliably benchmarking merge performance. #96122 (Anton Popov). - Add a new check enabled by default via setting
check_named_collection_dependenciesto avoid dropping named collections used by tables. #96181 (Pablo Marcos). - Added
system.fail_pointsto inspect existing failpoints in the server and whether they are enabled or not. This is going to help automate testing. #96762 (Pedro Ferreira). - Add role-based access to Glue catalog. Use settings
aws_role_arnand, optionally,aws_role_session_name. #90825 (Antonio Andelic). - Added a setting
add_minmax_index_for_temporal_columnsthat, when enabled, automatically creates minmax indexes for allDate,Date32,Time,Time64,DateTime, andDateTime64columns. #93355 (Michael Jarrett). - Support for extended table aliases for JOINs (queries like
SELECT * FROM (SELECT 1) AS t(a) JOIN (SELECT 1) AS u(b) ON a = b). Closes #95131. #95331 (Yarik Briukhovetskyi). - Added support for
ALTER TABLE RENAME COLUMNfor Iceberg tables. Previously onlyADD COLUMN, DROP COLUMN, and MODIFY COLUMNwere supported. #97455 (murphy-4o).
Experimental Feature
- The text index is now GA. #96794 (Robert Schulze).
- The
QBitdata type for quantized bit-packed vector storage (used for approximate nearest-neighbor search) is now generally available and no longer requires enabling an experimental setting. #95358 (Raufs Dunamalijevs). - Vector search in ClickHouse can now use replicas in the cluster to distribute the load and search of vector index parts. This enables ClickHouse to support large vector indexes that exceed the memory capacity of a single VM. #95876 (Shankar Iyer).
- Add server-side AST fuzzer controlled by
ast_fuzzer_runsandast_fuzzer_any_querysettings. When enabled, the server runs randomized mutations of each query after its normal execution, discarding the results. #97568 (Alexey Milovidov). - Add
iiffunction to the experimental KQL dialect. #94790 (happyso). - Schema inference now respects
allow_experimental_nullable_tuple_type. When enabled, it allows inferred tuple types to beNullable(Tuple(...)), so missing nested objects can becomeNULLinstead of a tuple ofNULLelements. #95525 (Nihal Z. Miaji). - The
use_statistics_cachesetting is now enabled by default, so column statistics are cached in memory to speed up query optimization without needing to reload them from each part. #95950 (Han Fei).
Performance Improvement
- Allow any deterministic expression in Primary Key to be used for data skipping (e.g.
ORDER BY cityHash64(user_id)/ORDER BY length(user_id)). For deterministic expressions, ClickHouse can apply the expression to query constants and use the result in the primary key index for predicates like=,IN, andhas. If the expression is also injective (e.g.ORDER BY hex(p)orORDER BY reverse(tuple(reverse(p), hex(p)))), we can effectively use the index for the negated forms:!=,NOT IN, andNOT has. Closes #10685. Closes #82161. #92952 (Nihal Z. Miaji). - Improved storage format of statistics. All statistics are now stored in a single file. #93414 (Anton Popov).
- Allow parallelized read for remote table engines/functions in the filesystem cache. #71781 (Kseniia Sumarokova).
- Allow using userspace page cache with local files and object storage table functions. #77874 (Michael Kolupaev).
- Avoid unnecessary memcpy in userspace page cache. #77884 (Michael Kolupaev).
- The default for
concurrent_threads_scheduleris nowmax_min_fairinstead offair_round_robin. This improves fairness under high load by prioritizing queries with fewer allocated slots, so short-running queries aren't penalized by long-running ones. #95300 (Sergei Trifonov). - If a
FINALquery used primary key condition for filtering followed by skip indexes for other conditions, thePrimaryKeyExpandprocessing step will now only check the initial shortlisted primary key ranges for intersection. #94903 (Shankar Iyer). - When using parallel replicas with table functions like
s3(...), queries with a single subquery wrapping the table function are now automatically parallelized across replicas, whereas previously only direct table function references were parallelized. Closes #92264. #96332 (phulv94). - Enable splitting data and system files in cache into separate segments. #87834 (MikhailBurdukov).
- Speed up some hash join operations by implementing dynamic dispatch for
ColumnVector::replicate. #79573 (Raúl Marín). - Performance improvement for parallel hash join in cases of complex predicates. Previously, we were processing non-joined rows in one thread, which is suboptimal the idea of the optimization is to parallelize the processing of the non-joined rows across multiple threads. Can be toggled by the
parallel_non_joined_rows_processingsetting. Enabled by default. #92068 (Yarik Briukhovetskyi). - Slightly optimize parsing of JSON type. #93614 (Pavel Kruglov).
- Improve memory footprint of AST. Optimization makes sense as fields are not used when highlighting is not used and there is no VALUES parsing. #93974 (Ilya Yatsishin).
- Optimize memory consumption of named Tuple AST objects. Place column names as strings in tuple object instead of having them in generic AST literal nodes. #94704 (Ilya Yatsishin).
- Devirtualization is improved with additional linker options. #94737 (Nikita Taranov).
- Improve clone replica performance for ReplicatedMergeTree tables with many parts by batching ZooKeeper requests. #94847 (c-end).
- When read step already has PREWHERE filters a new filter couldn't be added. This change postpones PREWHERE optimization until after JOIN runtime filter optimization so that runtime filters can be also pushed to PREWHERE. #95838 (Alexander Gololobov).
- Speedup
T64codec compression by using dynamic dispatch on x86. #95881 (Raúl Marín). - Speed up
uniqover numeric types by batching inserts when possible (not null, not -If, no GROUP BY, no IPv6 or String). #95904 (Raúl Marín). - Low-level optimizations for Keeper:
ZooKeeper::observeOperationshas been found to account for >20% of the ZooKeeper receive thread CPU consumption. This change addresses that by: 1. ForAggregatedZooKeeperLog::stats, useCityHash64instead ofSipHashwhich is >10x faster. 2. ForCoordination::ErrorCounter, usestd::array<std::atomic<UInt32>, N>instead ofstd::unordered_mapandstd::mutex. #95962 (Miсhael Stetsyuk). - Remove 64-byte alignment for ProfileEvents::Counter to save memory. #96097 (Azat Khuzhin).
- Memory optimization: trim size of
CachedOnDiskReadBufferFromFilestructure 50x. #96098 (Azat Khuzhin). - Don't copy old data on hash table resizing if it's empty. #96180 (Raúl Marín).
- Support JOIN runtime filters for
RIGHT OUTERJOINs. #96183 (Hechem Selmi). - The optimization
enable_join_runtime_filtersis now the default. #89314 (Alexey Milovidov). - Previously, text index direct read optimization was applied only when all parts had a materialized text index. This PR adds partial support: if some parts have a materialized text index, those parts will use it, while parts without a materialized text index will fall back to executing the original filter expression. #96411 (Anton Popov).
- Added
minmaxsecondary indexes on time columns andbloom_filterindexes onquery_id/initial_query_idcolumns to system log tables for faster filtering. #96712 (Alexey Milovidov). - Lazy materialization optimization is now applied to all branches of a
UNION ALLquery, not just the first one. Queries that combine multiple sorted and limited reads from differentMergeTreetables viaUNION ALLwill now benefit from deferred column reading on every branch, reducing I/O. #96832 (Federico Ginosa). - Optimize minmax skip index computation during INSERT by removing an unnecessary data copy and enabling vectorized min/max calculation for numeric columns. #97392 (Raúl Marín).
- Storage
DeltaLakenow takescount()result from delta lake metadata and shows correct table stats in system.tables (total bytes/rows). #96190 (Kseniia Sumarokova). - The unused columns are removed also from the reading step in case of reading from a MergeTree. It is especially useful when a filter is pushed down into
PREWHERE. #89982 (János Benjamin Antal). - Improved processing
SHOW TABLESquery by fetching only names of tables and improved getLightweightTablesIterator to return structure containing only table names. resolves #93835. #94467 (Smita Kulkarni). - Improve
assumeNotNull,coalesce,ifNullto enable primary key and skip index pruning for range predicates when key columns are wrapped in these functions. Closes #94689. #94754 (Nihal Z. Miaji). - Add with_data & with_stat extension to getChildren Keeper request. This allows fetching not only the list of children, but also their
statand/ordatain a single operation. #94826 (Nikolay Degterinsky). - The index analysis is done only once (in most cases) regardless of whether we end up executing a local plan or a plan with parallel replicas. #94854 (Nikita Taranov).
- Allow to enable distributed index analysis based on amount of parts (
distributed_index_analysis_min_parts_to_activate) and indexes size (distributed_index_analysis_min_indexes_size_to_activate). #95216 (Azat Khuzhin). - Enable PREWHERE optimization for Iceberg tables. #95476 (Konstantin Vedernikov).
- Reduce the memory footprint of some AST classes. #95514 (Raúl Marín).
- Limit the number of pipeline streams generated with
split_intersecting_parts_ranges_into_layersenabled. Helps to avoid excessive memory consumption. #96478 (Nikita Taranov). - Implement equivalent sets optimization for multiple joins. Queries with multiple consecutive
INNER JOINoperations now benefit from improved filter pushdown optimization. When tables are joined on equivalent columns (e.g.,t1 JOIN t2 ON t1.id = t2.id JOIN t3 ON t2.id = t3.id WHERE t1.id > 10), filters applied to any table in the chain are automatically pushed down to all tables. Close #96550. #96596 (Vladimir Cherkasov). - Optimize delta lake metadata scan. Uses changes from delta-kernel PR https://github.com/delta-io/delta-kernel-rs/pull/1827. #96686 (Kseniia Sumarokova).
- In Replicated database, don't update the cached cluster for every dummy query. #96897 (Tuan Pham Anh).
- Use the primary key index when filtering with
startsWithUTF8if the prefix contains only ASCII characters. #97055 (vkcku).
Improvement
- Add OpenTelemetry tracing for Keeper requests. #91332 (Miсhael Stetsyuk).
- New configuration options:
logger.startup_console_level&logger.shutdown_console_levelto allow for overriding the console log level during the startup & shutdown of ClickHouse respectively. #95919 (Garrett Thomas). - Respect command-line overrides when reloading configuration. Closes #80294. #80295 (Alexey Milovidov).
- Allow key-value overrides for named collection parameters in
mongodbtable function. #89616 (vanchaklar). - The read-in-order optimization for Iceberg tables now works with complex sorting functions like
icebergBucketandicebergTruncate, not just simple column references. #90256 (Konstantin Vedernikov). - Add a new column named parts_postpone_reasons in system.mutations to improve diagnostics, which shows the parts postpone reasons. #92206 (Shaohua Wang).
- Track changes in the number of rows to read (due to inserts/deletes or query condition cache usage) in
DataflowStatisticsCache. #93636 (Nikita Taranov). - Support SYSTEM RESET DDL WORKER [ON CLUSTER] query. It requests to reset the state of DDLWorker in its main thread. It is helpful to refresh the replica active when host IDs are updated. #93780 (Tuan Pham Anh).
- Support
mutation_idsinsystem.part_logfor event type ofMUTATE_PARTandMUTATE_PART_START. #93811 (Shaohua Wang). - Background operations (Mutate, Merge) can now be configured independently via 'background' profile. Previously such operations shared settings with regular queries via 'default' profile. #93905 (Arsen Muk).
- Add more information to
system.crash_log. #94112 #95857 (Miсhael Stetsyuk). - Added new
QueryNonInternalmetric to track the number of executing non-internal queries. This metric is exposed asClickHouseMetrics_QueryNonInternaland helps operators monitor query concurrency against themax_concurrent_querieslimit, which only applies to non-internal queries. #94284 (Ashwath Singh). - Support input bytes statistics collection for columns from compact parts in
RuntimeDataflowStatisticsCacheUpdater. #94626 (Nikita Taranov). - Add a check for Keeper misconfiguration leading to cluster assembly failures. Closes #60932. #94682 (Konstantin Bogdanov).
- Improve JSON prefixes deserialization during part loading. #94848 (Pavel Kruglov).
- Refactor the write using full INSERT pipeline, which triggers materialized views on the target table. #94890 (Kai Zhu).
- Use vector similarity search plan optimizations only if the index exists for the search column. #94998 (Eduard Karacharov).
- Check for the total memory limit before the user authentication and throw
(total) memory limit exceededif the total limit is more than allowed. #95003 (Nikolai Kochetov). - Added the
throw_on_unmatched_row_policiesconfiguration option which, when enabled, throws an exception if a user queries a table that has row policies but none of them apply to that user — preventing the ambiguous behavior of returning all rows due to access control misconfiguration. #95014 (Vitaly Baranov). - Dynamic update s3 access tokens in long queries with unity catalog. This closes #93981. #95069 (Konstantin Vedernikov).
- Disable jemalloc's dirty page decay if ClickHouse is under sustained memory pressure for
memory_worker_decay_adjustment_period_msmilliseconds. Enable jemalloc's dirty page decay back if ClickHouse is working under normal conditions for same amount of time. #95145 (Antonio Andelic). - S3Queue auxiliary Zookeeper support using
keeper_pathsetting from s3Queue. #95203 (Diego Nieto). - Respect
max_parts_to_merge_at_oncein TTL drop part merges. #95315 (Kseniia Sumarokova). - Add
connection_addressandconnection_portto query_log to reflect physical connection (addressandportare replaced when connected through proxy and auth_use_forwarded_address=1). #95471 (Yakov Olkhovskiy). - Fix incorrect memory accounting for the query conditions cache. The key problem was that it didn't take into account the cache key that composed of several strings (like part_name, the table id and the whole SQL condition). #95478 (Nikita Mikhaylov).
- Server started with the embedded configuration will allow to manipulate users and grants, saving them to the
accessdirectory, as the regular configuration does. This improves testing. Also enabled all access_control_improvements in the embedded config and in clickhouse-local. #95481 (Alexey Milovidov). - Improved S3 authentication error messages to include a hint to check credentials when access is denied. #95648 (Gerald Latkovic).
- Enable statistics cache and set the update period of cache to 300s. #95841 (Han Fei).
- Add component name to
system.aggregated_zookeeper_log. #95882 (Antonio Andelic). - Skip object storage reads when querying
DeltaLaketables fromsystem.tables. #95899 (Antonio Andelic). - Enable
enable_max_bytes_limit_for_min_age_to_force_mergeby default if thecompatibilitysetting is26.2or higher. #95917 (Christoph Wurm). - Delta Lake is now available on macOS. Closes #95979. #95985 (Alexey Milovidov).
- In previous versions, when combining conflicting ALTER expressions with UPDATE and RENAME COLUMN, a logical error was thrown instead of a proper exception. Closes #70678. #96022 (Alexey Milovidov).
- Improve the help output for all ClickHouse applications and add a --no-sudo option with a few fixes. This is a continuation of #58244 from Ilya Yatsishin. #96025 (Alexey Milovidov).
- Add
distanceCosinealias forcosineDistancebecause all other distance functions already have alias of this form. #96065 (Raufs Dunamalijevs). - Add support for the
with_dataKeeper extension to improve table fetching in Database Replicated. #96090 (Nikolay Degterinsky). - Update chdig to v26.2.1 (new features and MacOS support). #96113 (Azat Khuzhin).
- Improve filter pushdown for
numbersandprimes. ClickHouse can now derive conservative value bounds fromWHEREconditions when exact bounds cannot be derived, and restrict sequence generation accordingly (for example, forWHERE number % 5 < 2 AND number > 100 AND number < 300, ClickHouse will only generate numbers between 100 and 300, then apply the predicate), avoiding unbounded scans. Closes #84853. Closes #93913. #96115 (Nihal Z. Miaji). - The formatter previously wrapped SELECT in parentheses when a
COMMENTclause was present to disambiguate parsing. Instead, outputCOMMENTbeforeAS SELECT, which eliminates the ambiguity without parentheses. #96293 (Alexey Milovidov). - The
allow_impersonate_userconfig setting is now located inside theaccess_control_improvementssection rather than being a standalone server setting. #96451 (Vitaly Baranov). - Make
core_dump.size_limitconfiguration setting hot-reloadable, to avoid having to restart servers for configuration changes to take place. #96524 (Miсhael Stetsyuk). - Improves CPU and real-time profiler interoperability with socket timeouts. #96601 (Sergei Trifonov).
- Prevent the resurrection of dropped data if ADD COLUMN is run quickly after the DROP COLUMN mutation. #96713 (Alexey Milovidov).
- Change
function_idtype insystem.instrumentationfrom LowCardinality(Int32) to Int32. #96726 (Copilot). - Synchronous waiting for mutations will respect query cancellation and time limits. #96756 (Alexey Milovidov).
- Added system command
SYSTEM RELOAD DELTA KERNEL TRACING <level>to be able to change delta-kernel logging, which can be useful for debugging. #96763 (Kseniia Sumarokova). - Filtering by IP address family, i.e.
dns_allow_resolve_names_to_ipv4/ipv6settings, are applied even if DNS cache is disabled. #96810 (c-end). - Better jemalloc introspection. #96840 (Azat Khuzhin).
- Fix
/playWeb UI throwingQUERY_CACHE_USED_WITH_SYSTEM_TABLEwhen querying system tables. #96869 (Alexey Milovidov). - Improve Web UI: change favicon to indicate running query state; display errors from auxiliary queries (loading databases and tables) instead of silently ignoring them. Closes #85055. #96883 (Alexey Milovidov).
- Make the left panel in
/playUI clickable to toggle the database list. #96884 (Alexey Milovidov). DROP DATABASEnow drops tables in reverse dependency order, improving crash-safety when the database contains tables with loading dependencies (e.g.Distributedtables usingjoinGet). #97057 (Alexey Milovidov).- Bump yaml-cpp to prevent skipping invalid YAML. #97333 (Azat Khuzhin).
- Show a loading indicator in the
play.htmlsidebar while tables are being fetched. #97531 (Alexey Milovidov). - Add a copy-to-clipboard button for raw query results in the built-in web UI (play.html). #97532 (Alexey Milovidov).
- Fix query obfuscator (
clickhouse-format --obfuscate) to produce parseable SQL in more cases. #97584 (Alexey Milovidov).
Bug Fix (user-visible misbehavior in an official stable release)
- After metadata-only ALTERs, such as extending the elements of Enums, the optimization of aggregation with projection may end up producing an exception. #84143 (Alexey Milovidov).
- Materialized views now use the database where they were created as execution context, meaning that: - it is possible to omit explicit database qualification on names referred in view's select query - if no explicit database qualification is given, the same database where the materialized view was created is assumed. #88193 (Dmitry Kovalev).
- Fix query parameter substitution in CREATE USER authentication methods when using ON CLUSTER. Query parameters in authentication methods (e.g., password) were not being replaced, causing UNKNOWN_QUERY_PARAMETER errors on remote nodes. #92777 (xiaohuanlin).
- Fixed inconsistencies in text index analysis for
has,mapContainsKey, andmapContainsValuefunctions. Previously, queries using these functions could return different results depending on whether the expression was evaluated with or without a text index. #93578 (Anton Popov). - Fix crash when attaching a table to a
MaterializedPostgreSQLdatabase ifdropReplicationSlotthrows during stack unwinding. #96871 (Alexey Milovidov). - Backups could crash the server if you do many concurrent backups clashing over the same files. #93659 (Alexey Milovidov).
- Fixes queries with parallel replicas and JOIN with non-MT table. Closes #92056. #93902 (Igor Nikonov).
- Fixes an issue when Iceberg columns with dot in names returned NULL as values. #94335 (Mikhail Koviazin).
- Fixed handling of UTF8 strings in
stringJaccardIndexUTF8and improve performance. #94613 (Joanna Hulboj). - Fix possible overflows in
WITH FILL STALENESS(that leads to UB or/and endless loops). Fix possible endless loop due to big jumps. Add old analyzer support (mostly for stress tests). #94663 (Azat Khuzhin). - Fix possible hung distributed queries when hostnames resolve to multiple addresses and a remote replica freezes. #94726 (c-end).
- Fix invalid result on joining multiple table expressions, when leftmost table expression is a
-Clustertable function. Resolves #89996. #94748 (Konstantin Bogdanov). - Fix incorrect primary key and skip index pruning for predicates involving
toWeek,toYearWeek,toStartOfWeek,toLastDayOfWeek, andtoDayOfWeek, and fix exceptions in some of these functions for valid queries withLowCardinality(String). #94816 (Nihal Z. Miaji). - Remove unnecessary skip permissions check in
ATTACHqueries for a view with SQL Security. This prevents potential privilege escalation when a user attaches a view with a definer without validating required access. #94865 (pufit). - Fixes a crash during
ReplicatedMergeTreestartup caused by concurrent removal ofdelete_tmp_*directories. #94892 (myeongjun). - Fix
INSERTinto Iceberg tables with materialized views losing deduplication information, which caused an exception. #94938 (Daniil Ivanik). - Fix a bug where
SYSTEM DROP QUERY CACHE TAG 'TAGNAME' ON CLUSTER <CLUSTERNAME>would drop the full cache on the cluster. #94978 (Rory Crispin). - Preserve constant index granularity (use_const_adaptive_granularity) after Vertical merges (v2 with a fix for Nested, and in general). #95013 (Azat Khuzhin).
- Fixes race in filesystem cache in version 26.1 after [ClickHouse/ClickHouse#82764](https://github.com/ClickHouse/ClickHouse/pull/82764). #95042 (Kseniia Sumarokova).
- Fix postgresql() table function canceling by KILL QUERY and cancel query (Ctrl+C) in clickhouse-client. #95136 (Roman Vasin).
- Fixed type inference for qualified columns from source tables when multiple joins are used with
USINGclause. Previously, subsequent joins incorrectly updated types of underlying source columns to a common supertype even when the column was not involved in that join (e.g., inSELECT t2.a FROM t1 LEFT JOIN t2 USING (a) LEFT JOIN t3 USING (a), thet2.acolumn is only used by the first join, so its type should be the supertype oft1.aandt2.a, excludingt3.a). This could lead to logical errors or crashes when functions expected different column types than what actually appeared in the execution plan. #95157 (Vladimir Cherkasov). - Make column transform only once during getting content of manifest .avro list and files. #95164 (Daniil Ivanik).
- Fix incorrect calculation of JSON column sizes that could lead to excessive memory usage or wrong column statistics. #95207 (Azat Khuzhin).
- Fixed inaccurate memory accounting when applying large patch parts after lightweight updates. Previously, applying large patches could cause excessive memory usage and result in the server process being killed by the OOM killer. #95231 (Anton Popov).
- Fix undefined behavior that could cause incorrect results or an exception when a distributed query with
max_parallel_replicasfell back to a local replica during index analysis. #95263 (Azat Khuzhin). - Fix aggregation of sparse columns for
sumand timeseries whengroup_by_overflow_modeis set toany. #95301 (Mikhail Koviazin). - Fix a reliability issue in
plain_rewritabledisk policy where a network error mid-way through unlinking a metadata file could leave the storage in an inconsistent state. #95302 (Mikhail Artemenko). - Replace Date with Date32 for iceberg. #95322 (Konstantin Vedernikov).
- The password argument of the
redistable function now will be masked in the logs and system tables (e.g.:query_log). #95325 (János Benjamin Antal). - Fix a bug where tables could be dropped or altered while a distributed query was still executing against them, potentially causing exceptions or incorrect results. #95356 (Azat Khuzhin).
- Fix a logical error in some cases when negative
LIMIT/OFFSETis used in distributed queries. #95357 (Nihal Z. Miaji). - Fix a bug where clickhouse-client would ask for password twice when connecting using ssh. #95372 (Isak Ellmer).
- Fix a data race in storage S3(Azure)Queue. #95385 (Kseniia Sumarokova).
- Fix the prewhere filter error caused by lambda expressions in prewhere. #95395 (Xiaozhe Yu).
- Fix
optimize_syntax_fuse_functionsto not rewritesum/count/avgintosumCount()when the aggregate argument isNullable. Closes #95390. #95441 (Nihal Z. Miaji). - Avoid possible crash for distributed queries in case of cancellation. #95466 (Aleksandr Musorin).
- Fix deduplication for streaming from S3(Azure)Queue engine. #95467 (Kseniia Sumarokova).
- Fix updating row policies assigned to the initial user in distributed queries. #95469 (Vitaly Baranov).
- Fix check for encrypted disks over plain_rewritable (Fixes possible
It is not possible to register multiple plain-rewritable disks with the same object storage prefix). #95470 (Azat Khuzhin). - The
mergeTreeProjectiontable function was missing an access check, allowing users without SELECT permission on a table (but with permissions for table functions) to read data from its projections. This fix adds the same access check thatmergeTreeIndexandmergeTreeAnalyzeIndexesalready have. #95480 (Alexey Milovidov). - Fix possible logical error during reading of size subcolumn from dynamic subcolumns of Dynamic/JSON types. #95573 (Pavel Kruglov).
- Fix regression in (experimental) zero‑copy replication introduced by #94262 where shared parts could be deleted before other replicas finished fetching them. #95597 (filimonov).
- Fix crash during
tupleElementapplied to arrays of JSON. Closes #95581. #95647 (Pavel Kruglov). - Fix logical error exception when using a matcher (
*) inside a lambda function within a VALUES clause in a JOIN with USING. Close #93675. #95661 (Vladimir Cherkasov). - Fixed
There was an error: Cannot obtain error messagelogical error when waiting for a distributed DDL and dropping the Replicated database concurrently. Fixes #95539. #95664 (Alexander Tokmakov). - Fix
INfunction returning incorrect results withNULLvalues whentransform_null_inis enabled. Closes #65776. #95674 (Nihal Z. Miaji). - Correctly handle LowCardinality Nullable types in
CASTwhen the settingcast_keep_nullableis enabled. Closes #95670. #95747 (Alexey Milovidov). - Fix squashing partitioned delta lake data. #95773 (Kseniia Sumarokova).
- Fix race condition for Nullable join column in runtime filters. #95775 (Hechem Selmi).
- Fix possible logical error in query with matcher (
*,table.*) andanalyzer_compatibility_join_using_top_level_identifierwhenUSINGcolumn has different types in tables and select list. Close #90477. #95808 (Vladimir Cherkasov). - Fix memory safety bugs in parallel thread pool operations (backups, aggregation, distributed queries) that could cause exceptions when an error occurred during task scheduling. #95818 (Raúl Marín).
- Fixes a crash on the DROP WORKLOAD while running concurrently with queries using the workload being dropped. #95856 (Alexey Milovidov).
- Fix slow performance when querying system tables with a user that has limited grants on many databases. Closes #89371. #95874 (pufit).
- Fix executing tupleElement on JSON with nested paths, previously it could lead to wrong query result. #95907 (Pavel Kruglov).
- Fixed a
NOT_SUPPORTEDerror that could occur when using thedirectjoin algorithm with an empty MergeTree table. #95935 (Vladimir Cherkasov). - Fix the client not suggesting and auto-completing alias names for settings, closes #92190. #95945 (phulv94).
- Fix event_date in system.asynchronous_metric_log. #95947 (Raúl Marín).
- Fix skipping paths in JSON data type. Previously with
JSON(SKIP path)all JSON keys with prefixpathwere skipped, even keys like"pathpath", so it could lead to data loss for these paths during insert. Now it's fixed and only key"path"is skipped. #95948 (Pavel Kruglov). - Part with unknown projections should not be marked as lost forever. #95952 (Mikhail Artemenko).
- Fix empty string becoming
NULLinJointable withNullable(String)key. Closes #71414. #96002 (Alexey Milovidov). - Now the PostgreSQL engine can correctly read
BOOLEAN[]. Closes #72754. #96006 (Alexey Milovidov). - Fix the
ProtobufListformat for the case of reading from an empty file. Closes #70059. #96007 (Alexey Milovidov). - Fix
ProtobufListformat producing ghost record for empty tables. Closes #72596. #96010 (Alexey Milovidov). - Fix
iffunction type mismatch betweenUInt64andInt32in an unusual case of distributed queries and PREWHERE, with type inference. Closes #70017. #96012 (Alexey Milovidov). - Fix
JITcompiled queries involvingBooltypes. #96013 (Alexey Milovidov). - Fix logical error when reading UUID column from SQLite TEXT column. Closes #71263. #96016 (Alexey Milovidov).
- Fix SQLite engine type conversion for
DateTime,Date,UUID, and other types. Closes #73481. #96017 (Alexey Milovidov). FixedStringvalues were escaped incorrectly in queries to external databases, SQLite and PostgreSQL. Closes #73519. Co-authored with @jh0x. #96019 (Alexey Milovidov).- Fix assertion failure in WindowTransform with a large PRECEDING offset. Closes #75852. #96026 (Alexey Milovidov).
- Fix a bug with possible data corruption when concurrent async inserts are using the same parameter names but contain different values. #96035 (Seva Potapov).
- Fix period for global profilers (controlled by
global_profiler_real_time_period_nsandglobal_profiler_cpu_time_period_ns). Instead of set value, a truncated value was used, causing profiler to wakeup more than intended. #96048 (Antonio Andelic). - Earlier if reference data file inside iceberg manifest file for position delete was present in an entry but was null, we didn't get correct bounds for a corresponding data files. This PR fixes this bug. #96061 (Daniil Ivanik).
- Fix revoking default roles. #96103 (Vitaly Baranov).
- Fix use-after-free in the index analysis in a rare combination of disabled
use_primary_keyand a very large number of disjunctions of conditions that use the index. #96112 (Alexey Milovidov). - Fix a regression with the
Gorillacodec when an explicitly specified size does not correspond to the data type size, and the buffer size is too small. In previous versions, it threw an exception on decompression. Closes #78253. #96118 (Alexey Milovidov). - Avoid a deadlock in dictionaries loaded when one dictionary references a Merge table that references it recursively. Closes #78360. #96120 (Alexey Milovidov).
- Fix use-of-uninitialized-value in
formatDateTimewith non-fixed-width formatters, such as MySQL and JODA-style. #96133 (Alexey Milovidov). - The combination of settings
use_const_adaptive_granularityandindex_granularity_bytes(which means "non-adaptive granularity") led to a miscalculation of the number of rows to read and an exception. #96143 (Alexey Milovidov). - Running an invalid ALTER UPDATE mutation on object storage file-like tables, such as S3 and Azure, could lead to a nullptr dereference. Closes #92994. #96162 (Alexey Milovidov).
- Fix
AccessRights::containsreturning incorrect results with partial revokes. #96170 (pufit). - Fix query condition cache hash collision for CTE folded constants, which could lead to a wrong query result. Closes #96060. #96172 (Alexey Milovidov).
- Fix possible deadlock in ProcessList. It can happen because of possible lock inversion if memory overcommit tracker triggers when we are adding task to cancellation checker. #96182 (Antonio Andelic).
- Fixed a bug where queries involving outer joins (LEFT, RIGHT, or FULL) combined with multiple INNER JOINs could return incorrect results due to illegal join reordering. When an outer join's ON condition referenced columns from multiple previously joined tables, the optimizer failed to account for all table dependencies and could reorder the joins incorrectly, producing missing rows. Close #95972. #96193 (Vladimir Cherkasov).
- When a table has no statistics defined, ClickHouse shouldn't try to load them. This avoids some overhead (100+ms) for checking if the statistics files exist. (issue #96068). #96233 (Han Fei).
- Fix
optimize_syntax_fuse_functionsto not rewritesum/count/avgintosumCount()when the aggregate argument isLowCardinality(Nullable). Closes #95390. #96239 (Nihal Z. Miaji). - Fix incorrect partition pruning for
not INandnot hasfunction in some cases. #96241 (Nihal Z. Miaji). - Fix
stack-use-after-scopein the vector similarity index. #96259 (Alexey Milovidov). - Fix test runner not recognizing error hint comments when a query is preceded by a SQL comment. #96336 (Yakov Olkhovskiy).
- Fix logical error in KeyCondition when a table has a nullable primary key, and the query uses the
coalescefunction, which has its first argument constant. #96340 (Alexey Milovidov). - The interaction of
GROUPING SETS,group_by_use_nulls, and theTupledata type withLowCardinalityinside it, could produce an unexpected block structure in the query pipeline, which led to a logical error. This appeared after the introduction ofNullableTuples. #96358 (Alexey Milovidov). - It was possible to create a table with an empty expression
()as an index, which led to an invalid memory access. #96363 (Alexey Milovidov). - Fixed crash in old analyzer if JOIN and duplicated aliases. #96405 (Ilya Golshtein).
- Fix
Nested columns sizes are inconsistent with local_discriminatorserror due to a wrong in-place filtering optimization for Variant columns. #96410 (Alexey Milovidov). - Fix
CREATE TABLE ... CLONE AS ...ignoring full qualifier of source table. #96415 (Hasyimi Bahrudin). - Fix
mysqltable function canceling by KILL QUERY and cancel query (Ctrl+C) in clickhouse-client. #96437 (Roman Vasin). - Fixes livelock in the cancellation checker thread for queries with high
max_execution_timevalues. #96450 (Sergei Trifonov). - Fix a logical error in some cases when fractional
LIMIT/OFFSETis used in distributed queries. #96475 (Nihal Z. Miaji). - Fix null pointer dereference in certain expressions with lambda functions. #96479 (Alexey Milovidov).
- Fix incorrect results when
LowCardinalitycolumns are converted toNullable. #96483 (Nihal Z. Miaji). - Fix a crash when creating an Iceberg table with an
ORDER BYclause referencing a non-existent column or using a positional argument. Closes #93280. #96484 (Konstantin Vedernikov). - Fix runtime filter exception for Tuple columns with Nullable subfields. #96509 (Alexey Milovidov).
- Fix
LOGICAL_ERRORexception in Parquet V3 native reader whenPREWHEREfilter column contains non-boolean UInt8 values. #96594 (Alexey Milovidov). - Fix implicit index regeneration in replicated tables during metadata changes. #96600 (Raúl Marín).
- Fixes a datarace on DROP WORKLOAD. #96614 (Sergei Trifonov).
- Fix a bug in Iceberg table writes where partitioned inserts could produce incorrect data distribution across partition files. #96620 (Konstantin Vedernikov).
- Fixed
heap-use-after-freeinCREATE TABLEwith constraints. #96669 (Nikita Taranov). - Validate witness version in bech32 to avoid buffer overflow. #96671 (Raúl Marín).
- Fix
system.tablesreturning errors when a Data Lake REST catalog is created with an invalidauth_headersetting. #96680 (Han Fei). - Fix
min(timestamp)returning epoch (1970-01-01) via_minmax_count_projectionafter TTL merge when all rows in a block are filtered out. #96703 (Raquel Barbadillo). - Improve validation of the
iceberg_metadata_file_pathsetting to prevent path traversal and ensure the specified metadata file is within the table directory. #96754 (Daniil Ivanik). - Fix crash in
ifNullwithVariantargument used inGROUP BY. #96790 (Alexey Milovidov). - Fixed cache key collisions between tables with
table_disk=1setting. #96818 (Raufs Dunamalijevs). - Fix MemoryWorker's purging thread being stuck because of a race condition. #96819 (Antonio Andelic).
- Don't log data with credentials in iceberg catalogs. #96831 (Konstantin Vedernikov).
- Fix exit status of clickhouse-client after server error. #96841 (Vitaly Baranov).
- Queries with CROSS JOINs and enabled parallel replicas could return incorrect result. Fixes #74337. #96848 (Igor Nikonov).
- Fixed
ALTER TABLE DROP COLUMNqueries failing after a lightweight update was previously performed on the same column. #96861 (Anton Popov). - Fix stack overflow (crash) when creating archive-based backups (
.zip,.tzst) to aplain_rewritableobject storage disk. #96872 (Alexey Milovidov). - Fix server crash when backup fails due to full disk or other I/O errors on the destination filesystem. #96873 (Alexey Milovidov).
- Fix
EXCEPT ALLandINTERSECT ALLignoring row multiplicities and behaving like theirDISTINCTcounterparts. #96876 (Alexey Milovidov). - Fix
std::terminateexception inindexOfAssumeSortedwhen called with incompatible types (e.g.,IPv4array with integer search value). #96877 (Alexey Milovidov). - Fix exception
Bad cast from type DB::ColumnNullable to DB::ColumnStringwhen using window functions withgroup_by_use_nulls = 1and CUBE/ROLLUP/GROUPING SETS. #96878 (Alexey Milovidov). - Fix incorrect results when JIT-compiled expressions convert
DateTimetoDateTime64(e.g., inCASE/if/multiIfwith mixed DateTime types). The value was reinterpreted instead of properly scaled, producing wrong timestamps after expression compilation kicked in. #96879 (Alexey Milovidov). - Fix logical error exception in
CoalescingMergeTreewhen a skip index expression produces a constant column (e.g.,bloom_filteronifNotFinite(1, c0)for an integer column). #96880 (Alexey Milovidov). - Fix wrong port number in error message when accidentally connecting with HTTP to the TLS-enabled native protocol port. #96881 (Alexey Milovidov).
- Fix per-subquery
SETTINGSnot being applied to table functions likefilein CTEs and subqueries. #96882 (Alexey Milovidov). - Fix memory leak of BIO objects when reading X509 certificates. #96885 (Alexey Milovidov).
- Fix
LOGICAL_ERRORexception in query analyzer when a lambda expression is passed where a concrete value is expected (e.g., as the accumulator argument ofarrayFold). #96892 (Alexey Milovidov). - Fix
ColumnNullable is not compatible with originalexception when casting complex nested types (Array of Nullable Tuple containing Map with Nullable Enum values). #96924 (Alexey Milovidov). - Fix a race condition in sharded
HASHEDdictionary parallel loading that could occasionally cause some rows to not be loaded. #96953 (Alexey Milovidov). - Fix a race condition between
REPLACE PARTITIONand background mutations that could result in both old and new data being visible after the replace. #96955 (Alexey Milovidov). - Fix
arrayJoinfunction producing duplicate rows when used with INNER JOIN and WHERE clause, caused by the partial predicate push-down optimization incorrectly pushing filters containingarrayJoinbelow a JOIN. #96989 (Alexey Milovidov). - Fix crash (SEGFAULT) in
clearCachescaused byBlockIO::operator=not movingquery_metadata_cache, leading to premature destruction of cached storage snapshots and use-after-free ofMergeTreeDatastorage. #96995 (Alexey Milovidov). - Fix assertion failure in
IfTransformStringsToEnumPasswhen theifortransformfunction returnsNullable(String)(e.g. withGROUP BY ... WITH CUBEandgroup_by_use_nulls = true). #97002 (Alexey Milovidov). - Fix incorrect data written during
INSERT ... SELECTwithUNION ALLandJOIN, where constant string columns could receive wrong values after block squashing. #97019 (Hasyimi Bahrudin). - Fix
assert_castexception (or silent data corruption in release builds) when building column statistics afterALTER TABLE MODIFY COLUMNchanges the column type. #97027 (Alexey Milovidov). - Fix reads of uninitialized memory in Azure Blob Storage, SSH protocol, and Arrow Flight interfaces. #97053 (Alexey Milovidov).
- Fix cases where indexes were affecting the result for queries with row policy/PREWHERE and FINAL. #97076 (Yarik Briukhovetskyi).
- Fix remaining race condition between
REPLACE PARTITIONand background mutations inMergeTreetables that could cause old data to reappear. #97105 (Alexey Milovidov). - Fix implicit indices with alias columns and do full validation before creating them. #97115 (Raúl Marín).
- Fix logical error in
FunctionVariantAdaptorwith functions requiring const arguments likearrayROCAUC. #97116 (Bharat Nallan). - Fix stuck mutations when
PartCheckThreadre-enqueues aGET_PARTfor an already-mutated part, leaving phantom entries inparts_to_do. #97162 (Alexey Milovidov). - Fix query plan row count estimation for subqueries with
ORDER BY ... LIMIT, which could cause the optimizer to choose a suboptimal join order. #97193 (Alexander Gololobov). - Fix
LOGICAL_ERRORexception inFunctionVariantAdaptorwhen a function operating on Variant columns returnsNothingtype, which can happen with empty arrays inUNION ALLqueries. #97213 (Alexey Milovidov). - Fix a data race during S3 multipart copy operations (e.g., during
BACKUP/RESTOREto S3) that could cause exceptions under concurrent access. #97227 (Azat Khuzhin). - Fix
LOGICAL_ERRORexception whenarrayJoininWHEREclause references columns from both sides of aJOIN. #97239 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception when reading.sizesubcolumn of a sparseNullable(String)in a Tuple with PREWHERE. #97264 (Alexey Milovidov). - Fix exception "Number of rows in lazy chunk does not match number of offsets" in
LazyMaterializingTransformwhen reading from tables with non-adaptive index granularity (index_granularity_bytes = 0) usingORDER BY ... LIMIT. #97270 (Alexey Milovidov). - Fix
SYSTEM RESTART REPLICAlosing table from database when table re-creation fails with a non-ZooKeeper exception (e.g. memory limit), causing metadata digest mismatches inDatabaseReplicated. #97276 (Alexey Milovidov). - Field
readonlyinsystem.merge_tree_settingsnow properly reflects that certain merge tree settings (e.g.index_granularity) are unconditionally readonly. #97277 (Robert Schulze). - Fix a crash during
count()optimization onMergeTreetables when the storage snapshot was created without data. #97281 (Pablo Marcos). - Fix a possible crash when resolving function names from debug information for stack traces. #97294 (Azat Khuzhin).
- Fix logical error with analyzer_compatibility_join_using_top_level_identifier and ALIAS columns. Close #96228. #97297 (Vladimir Cherkasov).
- Fix
LOGICAL_ERRORexception inapplyOrderwhen using text-indexed columns withQUALIFYclause. #97313 (Alexey Milovidov). - System table
system.functionsnow shows for internal functionscategories = 'Internal'instead ofcategories = ''. #97315 (Robert Schulze). - Query with RIGHT JOIN chain and enabled parallel replicas can produce incorrect result. Fixes #74341. #97316 (Igor Nikonov).
- Fix spurious
TABLE_UUID_MISMATCHerrors that could occur with refreshable materialized views and other scenarios where tables are renamed. #97323 (Azat Khuzhin). - Fix segfault in
StorageKeeperMapbackup due to use-after-free of dangling storage pointer in lazy backup batch. #97336 (Alexey Milovidov). - Fix the
existsfunction with a scalar subquery inside anALTER UPDATE/DELETEwhenmutations_execute_subqueries_on_initiatoris enabled. The scalar subquery was incorrectly evaluated, which could lead to an error or a corrupt mutation command that made the table unloadable on the next server restart. #97347 (Kirill Kopnev). - Fix logical exception
Unexpected return type from equals. Expected Nullable(UInt8). Got Const(LowCardinality(Nullable(UInt8)))when comparing NULL with a Variant column containing LowCardinality types. #97379 (Alexey Milovidov). - Fix a possible race condition when
EXCHANGE TABLESis executed in parallel with the sharded query cache enabled. #97411 (Konstantin Vedernikov). - Fix
LOGICAL_ERRORexception in Array-to-QBitconversion whennullable_sourcefrom an outerTuplewrapper replaces the converted array column with a mismatched column type. Closes #97389. #97413 (Alexey Milovidov). - Fix AST formatting roundtrip inconsistency for aliased tuple literals inside parentheses, e.g.,
(('a', 'b') AS x)was incorrectly reformatted astuple(('a', 'b') AS x). #97418 (Alexey Milovidov). - Fix an exception during asynchronous inserts with deduplication when a parsing failure produced an empty block with zero rows. #97460 (Sema Checherinda).
- Fix exception "Number of rows in lazy chunk does not match number of offsets" in
LazyMaterializingTransformwhen reading from tables with non-adaptive index granularity (index_granularity_bytes = 0) usingORDER BY ... LIMIT. #97482 (Alexey Milovidov). - Fix insert iceberg settings. Add alias for the
allow_experimental_insert_into_icebergsetting. #97483 (Konstantin Vedernikov). - Fix
ACCESS_DENIEDfor users withoutCREATE TEMPORARY TABLEpermission whenoptimize_inverse_dictionary_lookupoptimization rewritesdictGet(...)predicates. ClickHouse now skips the rewrite and executes the original expression. Closes #97269. #97484 (Nihal Z. Miaji). - Fix assertion failure (exception in debug/sanitizer builds) in
SetandMergeTreeIndexSetwhen processing columns with inner sparse subcolumns (e.g.,Tuplecolumns from MergeTree parts with different sparse serialization profiles). #97493 (Alexey Milovidov). - Fix a possible use after free in StorageKafka2. #97520 (Bharat Nallan).
- Fix
INTO OUTFILEwithTRUNCATEandinto_outfile_create_parent_directoriessetting when the output path contains directories. #97549 (Alexey Milovidov). - Fix
BAD_ARGUMENTSerror when querying tables with lambda expressions inside ALIAS columns through themerge()table function with the analyzer enabled. #97551 (Alexey Milovidov). - Fix
system.zookeeper_infoexception when Keeper zxid is 0. #97553 (Alexey Milovidov). - Fix a possible logical error in
ip_triedictionary when key type is not String. #97555 (Bharat Nallan). - Fix REST catalog OAuth authentication not working for the base
RestCatalog(it only worked for derived catalogs likeOneLakeCatalog). This broke the default REST catalog after BigLake catalog was introduced. #97561 (Konstantin Vedernikov). - Geometry functions (
perimeterSpherical,areaSpherical, etc.) now accept individual geometry subtypes (Polygon,Ring,Point, etc.) in addition to theGeometryvariant type. #97571 (Alexey Milovidov). - Fix
LOGICAL_ERRORexception when usingisNull/isNotNullon subcolumns ofNullable(Tuple(... Nullable(T) ...))types. Closes #97224. #97582 (Alexey Milovidov). - Fix null pointer dereference when applying patch parts during lightweight updates. #97583 (Alexey Milovidov).
BaseSettings::readBinarypasses the index fromaccessor.findtofield_infos[]without checking for the not-found sentinel value (i.e.,-1), which may cause astd::vectorout-of-bounds access. The issue was caught thanks to libcxx hardening. This probably happened during query plan deserialization when a newer server sends a setting unknown to an older server. The string-based read method already handles this correctly;readBinarywas missing the same check. #97585 (Miсhael Stetsyuk).- Fix incorrect query results for
UNION ALLqueries where one branch had a constant-false predicate — the branch would incorrectly read data instead of returning nothing. #97620 (Bharat Nallan). - Fix
IN (col)with a single column reference failing withUNSUPPORTED_METHODerror. #97646 (Alexey Milovidov). - Fix logical error exception during
GROUP BY ... WITH ROLLUP/CUBEwhen keys includeLowCardinality(Nullable(...))insideNullable(Tuple(...)). #97647 (Alexey Milovidov). - Fix AST formatting inconsistency for
NOT (1, 1, 1)that could causeLOGICAL_ERRORin debug builds. #97653 (Alexey Milovidov). - Fix
keeper-converterexception when encountering empty ZooKeeper transaction log files. #97673 (Alexey Milovidov).
Build/Testing/Packaging Improvement
- ClickHouse can be built with clang-23 (master). #95578 (Alexey Milovidov).
- Fix force
is_localto false whenbind_hostis configured and replace with integration test. Follow-up for #74741. #93109 #96018 (Zhigao Hong). - Stress tests: fix stress and upgrade tests in CI. ignore
no-{build}tags. add compatibility randomization. #94693 (Nikita Fomichev). - Publish parser_memory_profiler binary from build. Tool can be used to analyze AST memory consumption. #95826 (Ilya Yatsishin).
- Add
--symbolizeflag forparser_memory_profilertool that produces.heap.symfiles with resolved symbols in results. #96477 (Ilya Yatsishin). - Pin third-party Docker images in integration tests to specific versions. #96500 (Alexey Milovidov).
- Restore the possibility to link
OpenSSLdynamically. This is not recommended and not used by any production builds, but the option still exists for enthusiasts on the Internet. #96506 (Govind R Nair). - Reduce
magic_enumrange from [-100, 1000] to default [-128, 127] by using a per-type specialization forCoordination::OpNum, improving build time. #96632 (Alexey Milovidov). - Remove unnecessary C++ templates from Function classes to reduce build times. #96646 (Alexey Milovidov).
- Move
StorageSystemLicensesgeneration to configure time to improve build parallelism. #96697 (Alexey Milovidov). - Parallelize license scanning. #96727 (Raúl Marín).
- Add stateless functional test for SSH protocol support. #96996 (Alexey Milovidov).
- Add Kafka 3.9.0 to the stateless functional test infrastructure, enabling direct testing of Kafka and Kafka2 table engines using ClickHouse Keeper as ZooKeeper. Six new stateless tests cover basic produce/consume, virtual columns, INSERT, multiple formats, broken message handling, and Keeper-based offset storage. #96997 (Alexey Milovidov).
- Add a CI workflow to build PGO+BOLT optimized clang toolchain. #96991 (Alexey Milovidov).
- Use the PGO-optimized LLVM/Clang build in CI, which should give 20..30% build speed improvement. #97031 (Alexey Milovidov).
- Replace math functions from glibc with llvm-libc implementations. #90151 (Konstantin Bogdanov).
- Update Boost from 1.83 to 1.90, fixing a
devectorassertion failure in debug builds. #97037 (Alexey Milovidov). - Update
postgresto REL_18_1. #95189 (Konstantin Bogdanov). - Use
libexpat2.7.3. #95218 (Konstantin Bogdanov). - Use
OpenSSL3.5.5. #95345 (Konstantin Bogdanov). - Use
simdjsonv4.2.4. #97129 (Konstantin Bogdanov). - Use
libarchive3.8.5. #97131 (Konstantin Bogdanov). - Use
fast_floatv8.2.3. #97133 (Konstantin Bogdanov). - Use
abseil-cpp20260107.1,s2geometryto v0.13.1. #97134 (Konstantin Bogdanov). - Bump
libxml2to 2.15.1. #95574 (Robert Schulze). - Upgraded 7 Tier-3 integration test Docker images from EOL or removed base images to current supported versions. #97314 (Rahul).
- Add TPC-DS benchmark queries. #97349 (Raufs Dunamalijevs).
- Replace individual x86 instruction-set cmake options (
ENABLE_SSSE3,ENABLE_AVX2,NO_SSE3_OR_HIGHER,ARCH_NATIVE, etc.) with a single numericX86_ARCH_LEVELoption (1/2/3/4), matching the standard x86-64 microarchitecture levels already used by the runtime dispatch system. #97354 (Raúl Marín). - Avoid instantiating
division_by_nullable=truetemplate variants for non-division operations inFunctionBinaryArithmetic, reducing compilation time and binary size. #97496 (Raúl Marín). - Reduce the include footprint of
Exception.hby removing it from high-fan-out headers liketypeid_cast.h,assert_cast.h,Context_fwd.h,IDataType.h, and various Column headers. #97497 (Raúl Marín). - Always use bundled
compiler-rtheaders (sanitizer and XRay interfaces) instead of the host compiler's headers, and buildcompiler-rtlibraries from source by default. #97499 (Raúl Marín). - Avoid including boost/multiprecision headers in
wide_integer_impl.hon platforms with adequatelong double, improving build time. #96633 (Alexey Milovidov). - Implement LLVM Code Coverage job and enable it initially for master branch. #90952 (Alexey Bakharew).
- Enable fast libcxx hardening for release builds. This is mostly needed for out-of-bounds checks. Given performance tests results, no noticeable performance impact is expected. #94757 (Miсhael Stetsyuk).
ClickHouse release 26.1, 2026-01-29. Presentation, Video
Backward Incompatible Change
- Fix inconsistent formatting caused by an incorrect substitution of aliases in the formatter. This closes #82833. This closes #82832. This closes #68296. This change is potentially backward incompatible: when the analyzer is disabled, certain CREATE VIEW queries with IN referencing an alias cannot be processed. To prevent the incompatibility, enable the analyzer (it is enabled by default since 24.3). #82838 (Alexey Milovidov).
- Codecs
DEFLATE_QPLandZSTD_QATwere removed. Users are advised to convert existing data compressed withDEFLATE_QPLorZSTD_QATto another codec before upgrade. Note that in order to use the codecs, settingsenable_deflate_qpl_codecandenable_zstd_qat_codechad to be enabled. #92150 (Robert Schulze). - Improve UDF debugging by enabling stderr capture in
system.query_log.exception. Previously, UDF stderr was only logged to files and not exposed in query logs, making debugging impossible. Now stderr triggers exceptions by default and is fully accumulated (up to 1MB) before throwing, so complete Python tracebacks and error messages appear insystem.query_log.exceptionfor effective troubleshooting. #92209 (Xu Jia). - Empty column list in
JOIN USING ()clause is now considered a syntax error. Previously it was supposed to beINVALID_JOIN_ON_EXPRESSIONduring query execution. In some cases such as joining withJoinstorage it led toLOGICAL_ERROR, close #82502. #92371 (Vladimir Cherkasov). - Use partial match for SKIP REGEXP in JSON type by default. Closes #79250. #92847 (Pavel Kruglov).
- Revert "Allow INSERT into simple ALIAS columns" (Reverts ClickHouse/ClickHouse#84154). It does not work with custom formats, and is not guarded with a setting. #92849 (Azat Khuzhin).
- Setting to throw an error if a data lake catalog doesn't have access to object storage. #93606 (Konstantin Vedernikov).
- The
Lazydatabase engine is removed and no longer available. Closes #91231. #93627 (Alexey Milovidov). - Remove the
transposed_with_wide_viewmode of themetric_log- it is unusable due to a bug. It is no longer possible to definesystem.metric_logwith this mode. This partially reverts #78412. #93867 (Alexey Milovidov). - CPU scheduling for workloads is now preemptive by default. See
cpu_slot_preemptionserver setting. #94060 (Sergei Trifonov). - Escape index filenames to prevent broken parts. With this change ClickHouse will fail to load indices with non-ascii characters in their name created by previous versions. To handle it you can use the merge tree setting
escape_index_filenames. #94079 (Raúl Marín). - Format settings
exact_rows_before_limit,rows_before_aggregation,cross_to_inner_join_rewrite,regexp_dict_allow_hyperscan,regexp_dict_flag_case_insensitive,regexp_dict_flag_dotallanddictionary_use_async_executorwere changed to be regular (non-format) settings now. This is a purely internal change without user-visible side effects except in the (unlikely) case that you specified any of these settings in Iceberg or DeltaLake or Kafka or S3 or S3Queue or Azure or Hive or RabbitMQ or Set or FileLog or NATS table engine definitions. In these cases, these settings were previously ignored, now such definitions throw an error. #94106 (Robert Schulze). - The
joinGet/joinGetOrNullfunctions now enforceSELECTprivileges on the underlying Join table. After this change, executingjoinGet('db.table', 'column', key)requires the user to haveSELECTprivilege on both the key columns defined in the Join table and the attribute column being retrieved. Queries lacking these privileges will fail withACCESS_DENIED. To migrate, grant the necessary permissions usingGRANT SELECT ON db.join_table TO userfor full table access, orGRANT SELECT(key_col, attr_col) ON db.join_table TO userfor column-level access. This change affects all users and applications relying onjoinGet/joinGetOrNullwhere explicitSELECTgrants were not previously configured. #94307 (Vladimir Cherkasov). - Check
SHOW COLUMNSforCREATE TABLE ... AS ...queries. Previously, it checkedSHOW TABLES, which is an incorrect grant for this type of permission check. #94556 (pufit). - Make the
Hashoutput format independent of block sizes. #94503 (Alexey Milovidov). Note that this changes the output hash values compared to previous versions.
New Feature
- HTTP API and embedded Web UI for ClickHouse Keeper. #78181 (pufit and speeedmaster).
- Async insert deduplication now works with dependent materialized views. When collision by block_id occurs, the original block is filtered to remove rows associated with the block_id, and the remaining rows are transformed with all relevant materialized views select queries, this rebuilds original block without conflicting rows. #89140 (Sema Checherinda). It is allowed to use deduplication with async inserts when materialized views are involved. #93957 (Sema Checherinda).
- Introduced a new syntax and framework to simplify and extend projection index feature. This follows up https://github.com/ClickHouse/ClickHouse/pull/81021. #91844 (Amos Bird).
- Add text index support for
Arraycolumns. #89895 (Jimmy Aguilar Mena). - Enable
use_variant_as_common_typeby default, which lets you use incompatible types inside anArray, inUNIONqueries, and in branches ofif/multiIf/case. #90677 (Alexey Milovidov). - New system table
zookeeper_info. Implements #88014. #90809 (Smita Kulkarni). - Support the
Varianttype in all functions. #90900 (Bharat Nallan). - Adds a
ClickHouse_Infometric to the Prometheus/metricsendpoint containing mainly version information so it's possible to build charts tracking detailed version information over time. #91125 (Christoph Wurm). - Introduce a new four letter
rcfgcommand for keeper which allows to change cluster configuration. This command provides broader possibilities for configuration changes than standardreconfigurerequest. Command takesjsonstring as an argument. The whole set of bytes sent to TCP interface should look like this:rcfg{json_string_length_big_endian}{json_string}. Some examples of command may look like this:{"preconditions": {"leaders": [1, 2], "members": [1, 2, 3, 4, 5]}, "actions": [{"transfer_leadership": [3]}, {"remove_members": [1, 2]}, {"set_priority": [{"id": 4, "priority": 100}, {"id": 5, "priority": 100}]}, {"transfer_leadership": [4, 5]}, {"set_priority": [{"id": 3, "priority": 0}]}]}. #91354 (alesapin). - Add function
reverseBySeparatorwhich reverses the order of substrings in a string separated by a specified separator. Close #91463. #91780 (Xuewei Wang). - Adds new setting
max_insert_block_size_byteswhich control the formation of inserted blocks in finer detail. #92833 (Kirill Kopnev). - It is possible to execute DDL queries with
ON CLUSTERclause for a Replicated database if theignore_on_cluster_for_replicated_databasesetting is enabled. In this case, the cluster name will be ignored. #92872 (Kirill). - Implement
mergeTreeAnalyzeIndexesfunction. #92954 (Azat Khuzhin). - Add new setting
use_primary_key. Set it tofalseto disable granule pruning based on the primary key. #93319 (Nihal Z. Miaji). - Add
icebergLocalClustertable function. #93323 (Anton Ivashkin). - Added
cosineDistanceTransposedfunction that approximates the cosine distance between two points. #93621 (Raufs Dunamalijevs). - Add
filescolumn to system.parts table that shows the number of files in each data part. #94337 (Match). - Adds a max-min fair scheduler for concurrency control. Provides better fairness under high oversubscription, where many queries compete for limited CPU slots. Short-running queries are not penalized by long-running queries that have accumulated more slots over time. Enabled by the
concurrent_threads_schedulerserver settingmax_min_fairvalue. #94732 (Sergei Trifonov). - Added the ability for ClickHouse client to override TLS SNI when connecting to the server. #89761 (Matt Klein).
- Support temporary tables in
joinGetfunction calls. #92973 (Eduard Karacharov). - Support deletion vectors in
DeltaLaketable engine. #93852 (Kseniia Sumarokova). - Support deletion vectors for
deltaLakeCluster. #94365 (Kseniia Sumarokova). - Google cloud storage support for data lakes. #93866 (Konstantin Vedernikov).
Experimental Feature
- Move
QBitfrom Experimental to Beta. #93816 (Raufs Dunamalijevs). - Add support for
Nullable(Tuple). Setallow_experimental_nullable_tuple_type = 1to enable it. #89643 (Nihal Z. Miaji). - Support Paimon REST catalog, continuing from https://github.com/ClickHouse/ClickHouse/pull/84423. #92011 (JIaQi Tang).
Performance Improvement
- Setting
use_skip_indexes_on_data_readis now enabled by default. This setting allows filtering in a streaming fashion, at the same time as reading, improving query performance and startup time. #93407 (Shankar Iyer). - Improve performance of
DISTINCTonLowCardinalitycolumns. Closes #5917. #91639 (Nihal Z. Miaji). - Optimize
distinctJSONPathsaggregate function so it reads only JSON paths from data parts and not the whole JSON column. #92196 (Pavel Kruglov). - More filters pushed down JOINs. #85556 (Nikita Taranov).
- Support more cases for push down from join ON condition when the filter uses inputs only from one side. Support
ANY,SEMI,ANTIjoins. #92584 (Dmitry Novik). - Allow using equivalent sets to push down filters for
SEMI JOIN. Closes #85239. #92837 (Dmitry Novik). - Skip reading left side of hash join when right side is empty. Previously we were reading left side until first non-empty block, which might do a lot of work in case when there is heavy filtering or aggregation. #94062 (Alexander Gololobov).
- Using the "fastrange" (Daniel Lemire) method for partitioning data inside the query pipeline. This could improve parallel sorting and JOINs. #93080 (Alexey Milovidov).
- Improve performance of window functions when PARTITION BY matches or is a prefix of the sorting key. #87299 (Nikita Taranov).
- Outer filter is pushed down into views which allows applying PREWHERE on local and remote nodes. Resolves #88189. #88316 (Igor Nikonov).
- Implement JIT compilations for more functions. Closes #73509. #88770 (Alexey Milovidov with Taiyang Li).
- If a skip index used in a
FINALquery is on a column that is part of the primary key, the additional step to check for primary key intersection in other parts is unnecessary and now not performed. Resolves #85897. #93899 (Shankar Iyer). - Optimize performance and memory usage for fractional
LIMITandOFFSET. #91167 (Ahmed Gouda). - Fix using of faster random read logic for Parquet Reader V3 prefetcher. Closes #90890. #91435 (Arsen Muk).
- Improve performance of
icebergCluster. Closes #91462. #91537 (Yang Jiang). - Don't filter by virtual columns on constant filters. #91588 (c-end).
- Reduce INSERT/merges memory usage with wide parts for very wide tables by enabling adaptive write buffers. Add support of adaptive write buffers for encrypted disks. #92250 (Azat Khuzhin).
- Improved performance of full text search with text index and
sparseGramstokenizer by reducing the number of searched tokens in the index. #93078 (Anton Popov). - Function
isValidASCIIwas optimized for positive outcomes, i.e. all-ASCII input values. #93347 (Robert Schulze). - The read-in-order optimization now recognizes when ORDER BY columns are constant due to WHERE conditions, enabling efficient reverse-order reads. This benefits multi-tenant queries like
WHERE tenant='42' ORDER BY tenant, event_time DESCwhich can now use InReverseOrder instead of requiring a full sort.". #94103 (matanper). - Introduce Enum AST specialized class to store value parameters in (string, integer) pairs instead of ASTLiteral children to optimize memory consumption. #94178 (Ilya Yatsishin).
- Distributed index analysis on multiple replicas. Beneficial for shared storage and huge amount of data in cluster. This is applicable for SharedMergeTree (ClickHouse Cloud) and could be applicable for other types of MergeTree tables on a shared storage. #86786 (Azat Khuzhin).
- Reduce overhead of join runtime filters by disabling them in the following cases: - too many bits are set in the bloom filter - too few rows are filtered out at runtime. #91578 (Alexander Gololobov).
- Use an in-memory buffer for correlated subqueries input to avoid evaluating it multiple times. Part of #79890. #91205 (Dmitry Novik).
- Allow all replicas to steal orphaned ranges in parallel replicas reading. This improves load balancing and reduces long-tail latency. #91374 (zoomxi).
- External aggregation/sorting/join now respects query setting
temporary_files_codecin all contexts. Fixed missing profile events for grace hash join. #92388 (Vladimir Cherkasov). - Make query memory usage detection for spilling to disk during aggregation/sorting more robust. #92500 (Azat Khuzhin).
- Estimate total rows count and NDV (number of distinct values) statistics of aggregation key columns. #92812 (Alexander Gololobov).
- Optimize postings list compression with simdcomp. #92871 (Peng Jian).
- Refactor S3Queue Ordered mode processing with buckets. This should also improve performance, reducing the number of keeper requests. #92889 (Kseniia Sumarokova).
- Functions
mapContainsKeyLikeandmapContainsValueLikecan now leverage a text index onmapKeys()ormapValues(), respectively. #93049 (Michael Jarrett). - Reduce memory usage on non-Linux systems (enable immediate purging of jemalloc dirty pages). #93360 (Eduard Karacharov).
- Force purging of jemalloc arenas in case the ratio of dirty pages size to
max_server_memory_usageexceedsmemory_worker_purge_dirty_pages_threshold_ratio. #93500 (Eduard Karacharov). - Reduce memory usage for AST. #93601 (Nikolai Kochetov).
- In some cases we've seen ClickHouse doesn't respect a memory limit when reading from a table. This behaviour is fixed. #93715 (Nikita Mikhaylov).
- Enable
CHECK_STATandTRY_REMOVEKeeper extension by default. #93886 (Mikhail Artemenko). - Parse lower and upper bounds of file names corresponding to position deletes from Iceberg manifest file entries for better selection of corresponding data files. #93980 (Daniil Ivanik).
- Add two more settings to control maximum number of dynamic subcolumns in JSON column. First is MergeTree setting
merge_max_dynamic_subcolumns_in_compact_part(similar to already addedmerge_max_dynamic_subcolumns_in_wide_part) that limits number of dynamic subcolumns created during merge into a Compact part. Second is query level settingmax_dynamic_subcolumns_in_json_type_parsingthat limits number of dynamic subcolumns created during parsing of JSON data, it will allow to specify the limit on insert. #94184 (Pavel Kruglov). - Slightly optimize squashing of JSON columns for some cases. #94247 (Pavel Kruglov).
- Lower the thread pool queue sizes based on the production experience. Add an explicit memory consumption check before reading any data from the MergeTree. #94692 (Nikita Mikhaylov).
- Make sure the scheduler would prefer MemoryWorker thread under the CPU starvation, because it protects ClickHouse process from an existential threat. #94864 (Nikita Mikhaylov).
- Run purging of jemalloc dirty pages in a different thread from main thread of MemoryWorker. If purging is slow, it could delay updates of RSS usage which could lead to out of memory kills of the process. Introduce new config
memory_worker_purge_total_memory_threshold_ratioto start purging dirty pages based on ratio of total memory usage. #94902 (Antonio Andelic).
Improvement
system.blob_storage_logis now available for Azure Blob Storage. #93105 (Alexey Milovidov).- Implement
blob_storage_logfor Local and HDFS. Fix an error whenS3Queueused something other than the disk name for logging inblob_storage_log. Adderror_codecolumn toblob_storage_log. Split the test configuration file to simplify local testing. #93106 (Alexey Milovidov). clickhouse-clientandclickhouse-localwill highlight digit groups (thousands, millions, etc.) inside numeric literals while typing. This closes #93100. #93108 (Alexey Milovidov).- Adds support in
clickhouse-clientfor command-line arguments with a space surrounding the equals sign. Closes #93077. #93174 (Cole Smith). - With
<interactive_history_legacy_keymap>true</interactive_history_legacy_keymap>, the CLI client can now fall back to Ctrl-R for regular search like before, while Ctrl-T does fuzzy search. #87785 (Larry Snizek). - The statement to clear caches
SYSTEM DROP [...] CACHEgave the false impression that the statement disables the cache. ClickHouse now supports statementSYSTEM CLEAR [...] CACHEwhich is more obvious. The old syntax remains available. #93727 (Pranav Tiwari). - Support multiple columns as primary key in
EmbeddedRocksDB. Closes #32819. #33917 (usurai). - It is now possible to use non-constant IN for scalars (queries like
val1 NOT IN if(cond, val2, val3)). #93495 (Yarik Briukhovetskyi). - Prevent
x-amz-server-side-encryptionheaders from being propagated toHeadObject,UploadPart&CompleteMultipartUploadS3 requests as they're not supported. #64577 (Francisco J. Jurado Moreno). - Tracking hive partitioning for ordered mode in S3Queue. Resolves #71161. #81040 (Anton Ivashkin).
- Optimize space reservation in filesystem cache.
FileCache::collectCandidatesForEvictionwill be executed without unique lock. #82764 (Kseniia Sumarokova). - Support composite rotation strategy (size + time) for server log. #87620 (Jianmei Zhang).
- CLI client can now specify
<warnings>false</warnings>instead of the command line--no-warnings. #87783 (Larry Snizek). - Add support for the
avgaggregate function with Date, DateTime and Time values as arguments. Closes #82267. #87845 (Yarik Briukhovetskyi). - The optimization
use_join_disjunctions_push_downis enabled by default. #89313 (Alexey Milovidov). - Support more table engines and data source kinds in the correlated subqueries. Closes #80775. #90175 (Dmitry Novik).
- If the schema of parameterized view is specified explicitly, it is shown. Close #88875, #81385. #90220 (Grigorii Sokolik).
- Correctly handle the gap in Keeper log entries if logs are before the last committed index. #90403 (Antonio Andelic).
- Improve
min_free_disk_bytes_to_perform_insertsetting to work correctly with JBOD volumes. #90878 (Aleksandr Musorin). - Make it possible to specify
storage_class_namesetting in named collections forS3table engine ands3table function. #91926 (János Benjamin Antal). - Support inserting auxiliary zookeeper by
system.zookeeper. #92092 (RinChanNOW). - Add new metrics for the keeper:
KeeperChangelogWrittenBytes,KeeperChangelogFileSyncMicroseconds,KeeperSnapshotWrittenBytesandKeeperSnapshotFileSyncMicrosecondsprofile events as well asKeeperBatchSizeElementsandKeeperBatchSizeByteshistogram metrics. #92149 (Miсhael Stetsyuk). - Add a new setting,
trace_profile_events_list, which limits tracing withtrace_profile_eventto the specified list of event names. This allows more precise data collection on large workloads. #92298 (Alexey Milovidov). - Support SYSTEM NOTIFY FAILPOINT for pausable failpoints. - Support SYSTEM WAIT FAILPOINT fp PAUSE/RESUME. #92368 (Shaohua Wang).
- Add
creation(implicit/explicit) column tosystem.data_skipping_indices. #92378 (Raúl Marín). - Allow passing the description of columns for YTsaurus dyn tables to the dictionary source. #92391 (MikhailBurdukov).
- In #63985, we made it possible to specify all the parameters needed for TLS configuration on a per-port basis (see composable protocols), so we don't have to rely on global TLS config. However, the implementation still implicitly requires a global
openSSL.serverconfig section to exist, which conflicts with setups where different TLS configurations are needed for different ports. For example, in keeper-in-server deployments, we need separate TLS configs for inter-keeper communication and clickhouse client connections. #92457 (Miсhael Stetsyuk). - Introduce a new setting
input_format_binary_max_type_complexitythat limits the total number of type nodes that can be decoded in binary format to prevent malicious payloads. #92519 (Raufs Dunamalijevs). - Reflect running tasks in
system.background_schedule_pool{,_log}. Add documentation. #92587 (Azat Khuzhin). - Execute current query in Ctrl+R search in client if no history match found. #92749 (Azat Khuzhin).
- Support
EXPLAIN indices = 1as an alias forEXPLAIN indexes = 1. Closes #92483. #92774 (Pranav Tiwari). - Parquet reader now allows reading Tuple or Map columns as JSON:
select x from file(f.parquet, auto, 'x JSON')works even if the type of columnxinf.parquetis tuple or map. #92864 (Michael Kolupaev). - Support empty tuples in parquet reader. #92868 (Michael Kolupaev).
- Fallback to read-write copy for Azure Blob Storage when native copy fails with BadRequest (e.g. invalid block list). Previously this was only done for Unauthorized error which was seen while copying blob to different storage accounts. But we also sometimes see "The specified block list is invalid" error. So now updated the condition to fallback to read & write for all native copy fails. #92888 (Smita Kulkarni).
- Fix EC2 metadata endpoint throttling when running many concurrent S3 queries with EC2 instance profile credentials. Previously, each query created its own
AWSInstanceProfileCredentialsProvider, causing concurrent requests to the EC2 metadata service which could result in timeouts andHTTP response code: 403errors. Now the credentials provider is cached and shared across all queries. #92891 (Sav). - Rework
insert_select_deduplicatesetting to add an ability to keep backward compatibility. #92951 (Sema Checherinda). - Log background tasks that are slower than average (
background_schedule_pool_log.duration_threshold_milliseconds=30) to avoid excessive tasks logging. #92965 (Azat Khuzhin). - In previous versions, some of C++ function names were displayed incorrectly ("mangled") in the
system.trace_logandsystem.symbols, and thedemanglefunction didn't process them well. Closes #93074. #93075 (Alexey Milovidov). - Introduced the
backup_data_from_refreshable_materialized_view_targetsbackup setting to skip back up of refreshable materialized views. RMVs with APPEND refresh strategy which are always backed up. #93076 (Julia Kartseva). #93658 (Julia Kartseva) - Use minimal debug info instead of no debug info for heavy translation units, such as functions. #93079 (Alexey Milovidov).
- Added MinIO compatibility support to AWS S3 C++ SDK by implementing error code mapping for MinIO-specific errors. This change allows ClickHouse to properly handle and retry MinIO server errors when using MinIO deployments instead of AWS S3, improving reliability for users running object storage on self-hosted MinIO clusters. #93082 (XiaoBinMu).
- Write symbolized jemalloc profiles (eliminating the need for a binary during heap profile generation). #93099 (Azat Khuzhin).
- Resurrect
clickhouse git-importtool - it was broken on large and invalid commits. See https://presentations.clickhouse.com/2020-matemarketing/. #93202 (Alexey Milovidov). - Don't show passwords from URL storage in query log. #93245 (Konstantin Vedernikov).
- Support
Geometrytype forflipCoordinates. #93303 (Bharat Nallan). - Improve the UX of SYSTEM INSTRUMENT ADD/REMOVE: use String literals for function names, patch all functions that match and allow using function_name in
REMOVE. #93345 (Pablo Marcos). - Add a new setting
materialize_statistics_on_mergewhich enables/disables materializing statistics during merge. The default value is1. #93379 (Han Fei). - ClickHouse can now parse
SELECTwithout parentheses aroundDESCRIBE SELECTqueries. Closes #58382. #93429 (Yarik Briukhovetskyi). - Add randomization of cache correctness checks under probability. #93439 (Kseniia Sumarokova).
- Add setting
type_json_allow_duplicated_key_with_literal_and_nested_objectto allow duplicated paths in JSON where one is a literal and another is a nested object, e.g.{"a" : 42, "a" : {"b" : 42}}. Some data could be created before this restriction on duplicated paths was added in https://github.com/ClickHouse/ClickHouse/pull/79317 and further manipulation with this data can lead to errors now. With this setting, such old data cane still be used with no errors. #93604 (Pavel Kruglov). - Don't print values of simple types on separate lines in Pretty JSON. #93836 (Pavel Kruglov).
- When there are many
alter table ... modify setting ...statements, it's possible not to acquire lock for 5 seconds. Better to returntimeoutthanlogical error. #93856 (Han Fei). - Prevent excessive output on a syntax error. Before this change, it output the whole SQL script, which could contain a lot of queries. #93876 (Alexey Milovidov).
- Do proper byte size calculation of the
checkrequest with stats in Keeper. #93907 (Mikhail Artemenko). - Added
use_hash_table_stats_for_join_reorderingsetting to control whether runtime hash table size statistics are used for join reordering. This setting is enabled by default, preserving the existing behavior ofcollect_hash_table_stats_during_joins. #93912 (Vladimir Cherkasov). - Users can now partially view nested global server settings in the
system.server_settingstable (e.g.logger.level). This only covers settings with a fixed structure (no lists, enumerations, repetitions etc.). #94001 (Hechem Selmi). QBitcan now be compared for equality. #94078 (Raufs Dunamalijevs).- When Keeper detects broken snapshot or inconsistent changelogs, throw exception instead of manually aborting or cleaning up files automatically. This should lead to a safer behaviour of Keeper relying on manual intervention. #94168 (Antonio Andelic).
- Fix leaving possible leftovers in case of
CREATE TABLEfails. #94174 (Azat Khuzhin). - Fix uninitialized memory access (a bug in OpenSSL) when password protected TLS key is used. #94182 (Konstantin Bogdanov).
- Bump chdig to v26.1.1. #94290 (Azat Khuzhin).
- Support more generic partitioning for S3Queue ordered mode. #94321 (Bharat Nallan).
- Added alias
use_statisticsfor settingallow_statistics_optimize. This is more consistent with existing settingsuse_primary_keyanduse_skip_indexes. #94366 (Robert Schulze). - Enabled setting
input_format_numbers_enum_on_conversion_errorfor conversion from Numbers to Enums to check whether the element exists. #94384 (Elmi Ahmadov). - In S3(Azure)Queue ordered mode clean up failed nodes by tracking limits (before that was done only in Unordered mode for both failed and processed, so now this will also be done for Ordered but only for failed nodes). #94412 (Kseniia Sumarokova).
- Enable access management for
defaultuser in clickhouse-local. The default user inclickhouse-localwas missing the access_management privilege, which caused operations likeDROP ROW POLICY IF EXISTSto fail withACCESS_DENIEDerror, even though the user should be unrestricted. #94501 (Alexey Milovidov). - Enable named collection for YTsaurus dictionaries and tables. #94582 (MikhailBurdukov).
- Add support for SQL-defined named collections in BACKUP/RESTORE for S3 and Azure Blob Storage. Closes #94604. #94605 (Pablo Marcos).
- Support bucketing based on partition key for S3Queue in ordered mode. #94698 (Bharat Nallan).
- Add an asynchronous metric with the longest running merge elapsed time. #94825 (Raúl Marín).
- Add belonging file check before apply position delete using IcebergBitmapPositionDeleteTransform. #94897 (Yang Jiang).
- Now
view_duration_msshows the time when group was active, not the sum of the threads duration in it. #94966 (Sema Checherinda). - Remove limit of the max number of search tokens in
hasAnyTokensandhasAllTokensfunctions which was limited to 64. Example:SELECT count() FROM table WHERE hasAllTokens(text, ['token_1', 'token_2', [...], 'token_65']]);The query would result in aBAD_ARGUMENTSerror because there are 65 search tokens. With this PR, the limit has been removed completely and the same query would run without an error. #95152 (Elmi Ahmadov). - Add a setting
input_format_numbers_enum_on_conversion_errorfor conversion from Numbers to Enums to check whether the element exists. Closes: #56144. #56240 (Nikolay Degterinsky). - Share format parser resources between data file and position delete file reading in Iceberg tables to reduce memory allocations. #94701 (Yang Jiang).
Bug Fix (user-visible misbehavior in an official stable release)
- Fixes a bug where predefined query handlers would have trailing whitespace interpreted as data during inserts. #83604 (Fabian Ponce).
- Fix INCOMPATIBLE_TYPE_OF_JOIN error for Join storage and outer to inner join optimization applied. Resolves #80794. #84292 (Vladimir Cherkasov).
- Fix exception "Invalid number of rows in Chunk" when using hash join with
allow_experimental_join_right_table_sortingenabled. #86440 (yanglongwei). - Always replace file names to hash in MergeTree if filesystem is case insensitive. Previously on systems with case insensitive filesystem (like MacOS) it could lead to data corruption when several column/subcolumn names differs only in the case. #86559 (Pavel Kruglov).
- Add a full permissions check on the create stage for the underlying query inside a materialized view. #89180 (pufit).
- Fixed crash in
icebergHashfunction on constant argument. #90335 (Michael Kolupaev). - Fix logical error when mutation without transaction mutates parts in an active transaction, which is rolled back finally. #90469 (Shaohua Wang).
- Update
system.warningscorrectly after an ordinary database was converted to an atomic database. #90473 (sdk2). - Fixes an assertion when reading from Parquet file, and part of a prewhere expression is used elsewhere in the query. #90635 (Max Kainov).
- Fix crash in a single-node cluster when reading from Iceberg in split-by-buckets mode. This closes #90913. #91553 (Konstantin Vedernikov).
- Fix possible logical error in Log engine during subcolumns reading. Closes #91710. #91711 (Pavel Kruglov).
- Fix Logical error: 'Storage does not support transaction' during ATTACH AS REPLICATED. #91772 (Shaohua Wang).
- Fix for runtime filters working incorrectly when LEFT ANTI JOIN has extra post-condition. #91824 (Alexander Gololobov).
- Fixes an error where we have a null-safe comparison involving the Nothing type. Closes #91834. Closes #84870. Closes #91821. #91884 (Yarik Briukhovetskyi).
- Fix DELTA_BYTE_ARRAY decoding bugs in native Parquet reader affecting highly repetitive string data. #91929 (Daniel Muino).
- Cache schema only for the file it was inferred from in globs instead of all files during schema inference. Closes #91745. #92006 (Pavel Kruglov).
- Fix the
Couldn't pack tar archive: Failed to write all byteserror caused by an incorrect archive entry size header. Fixes #89075. #92122 (Julia Kartseva). - Release request stream in insert select to prevent closing http connection. #92175 (Sema Checherinda).
- Fix logical error for queries with multiple JOINs with
USINGclause andjoin_use_nulls. #92251 (Vladimir Cherkasov). - Fix logical error while join reordering with join_use_nulls, close https://github.com/clickhouse/clickhouse/issues/90795. #92289 (Vladimir Cherkasov).
- Fix inconsistent AST formatting of arrayElement with negate literal. Closes #92288 Closes #92212 Closes #91832 Closes #91789 Closes #91735 Closes #88495 Closes #92386. #92293 (Pavel Kruglov).
- Fix a possible crash with
join_on_disk_max_files_to_mergesetting. #92335 (Bharat Nallan). - Related issue #https://github.com/ClickHouse/support-escalation/issues/6365. #92339 (Tuan Pham Anh).
- Fix missing access check in
SYSTEM SYNC FILE CACHE. Closes #92101. #92372 (Kseniia Sumarokova). - Fix
count_distinct_optimizationpass over window functions and over multiple arguments. #92376 (Raúl Marín). - Fix "Cannot write to finalized buffer" error when using certain aggregate functions with window functions. Closes #91415. #92395 (Jimmy Aguilar Mena).
- Fix logical error with
CREATE TABLE ... AS urlCluster()and database engineReplicated. Closes #92216. #92418 (Kseniia Sumarokova). - Inherit source part serialization info settings during mutation in MergeTree. It fixes possible incorrect result of the query over mutated part after changes in data types serialization. #92419 (Pavel Kruglov).
- Fix possible conflict in column and subcolumn with the same name leading in using wrong serialization and query failures. Closes #90219. Closes #85161. #92453 (Pavel Kruglov).
- Fix a
LOGICAL_ERRORs that caused by not wanted modification of query plan when converting outer join to inner join. Also relax the requirements of optimization to be able to apply it in cases when injective functions are applied to the aggregating keys during joins. #92503 (János Benjamin Antal). - Fix possible error
SIZES_OF_COLUMNS_DOESNT_MATCHduring sorting of emty tuple column. Closes #92422. #92520 (Pavel Kruglov). - Check for incompatible typed paths in JSON type. Closes #91577. #92539 (Pavel Kruglov).
- Fix deadlock for SHOW CREATE DATABASE for Backup database. #92541 (Azat Khuzhin).
- Use proper error code when validating hypothesis index. #92559 (Raúl Marín).
- Fix dynamic subcolumns resolution in column aliases in analyzer. Previously dynamic subcolumn in column alias was wrapped in
getSubcolumnand in some cases could be not resolved at all. Closes #91434. #92583 (Pavel Kruglov). - Prevent crash in tokens() with null second argument. #92586 (Raúl Marín).
- Fix potential crash caused by in place mutation of underlying const PREWHERE columns. This could've happened at column shrinking (
IColumn::shrinkToFit) or filtering (IColumn::filter), which could've triggered concurrently from several threads. #92588 (Arsen Muk). - Creating and materializing text indexes on tables containing large parts (over 4,294,967,295 rows) is temporarily disabled. This limitation prevents incorrect query results, as the current index implementation does not yet support such large parts. #92644 (Anton Popov).
- Fixes a logical error
Too large size (A) passed to allocatorwhile executing JOINs. Closes #92043. #92667 (Yarik Briukhovetskyi). - Remove a bug that
ngrambf_v1indexes with ngram length (1st parameter) > 8 would throw an exception. #92672 (Robert Schulze). - Fix uncaught exception during background named collections reload when zookeeper storage is used. Closes https://github.com/ClickHouse/clickhouse-private/issues/44180. #92717 (Kseniia Sumarokova).
- Reworks incorrect logic in access grant checks for wildcard grants. The previous attempt https://github.com/ClickHouse/ClickHouse/pull/90928 addressed a critical vulnerability but ended up being too restrictive, resulting in some wildcard
GRANTstatements failing due to unrelated revokes. #92725 (pufit). - Fix bug in data skipping logic when
not match(...)is used inWHEREcausing incorrect results. Closes #92492. #92726 (Nihal Z. Miaji). - Do not attempt to delete temporary directories at startup if a MergeTree table is created over a read-only disk. #92748 (Alexey Milovidov).
- Fix "Cannot add action to empty ExpressionActionsChain" for ALTER TABLE REWRITE PARTS (v2). #92754 (Azat Khuzhin).
- Avoid crash due to reading from a disconnected
Connection. #92807 (Raufs Dunamalijevs). - Fix logical error
Failed to set file processing within 100 retriesin storgaeS3QueueinOrderedmode. It is now replaced with a warning. This error could happen before 25.10 version if keeper session expired, however it will still be a warning in 25.10+ versions, as it is still theoretically possible to get this error in case of high processing concurrency inOrderedmode. #92814 (Kseniia Sumarokova). - Previously, some queries that used PK sharding with a false condition were failing. Now they're not. Needed for https://github.com/ClickHouse/ClickHouse/pull/89313. #92815 (Yarik Briukhovetskyi).
- Fixed calculation of uncompressed sizes of text indexes in the
system.partstable. #92832 (Anton Popov). - Fixed usage of primary index in lightweight updates that have an
INclause with subqueries in the predicate of theWHEREclause. #92838 (Anton Popov). - Fix creating type hint for path 'skip' in JSON. Closes #92731. #92842 (Pavel Kruglov).
- In the S3 table engine, we should avoid caching the partition key if there are non-deterministic functions. #92844 (Miсhael Stetsyuk).
- Fix possible error
FILE_DOESNT_EXISTafter mutation of a sparse column withratio_of_defaults_for_sparse_serialization=0.0. Closes #92633. #92860 (Pavel Kruglov). - Fix parquet schema inference in the old parquet reader (not used by default) when a JSON column comes after a Tupe column. Fix the old parquet reader (not used by default) failing on empty tuples. #92867 (Michael Kolupaev).
- Fix logical error with multiple joins on constant condition and
join_use_nulls, close #92640. #92892 (Vladimir Cherkasov). - Fix possible error
NOT_FOUND_COLUMN_IN_BLOCKduring insert into a table with subcolumn in partition expression. Closes #93210. Closes #83406. #92905 (Pavel Kruglov). - Fix error
NO_SUCH_COLUMN_IN_TABLEin Merge engine over tables with aliases. Closes #88665. #92910 (Pavel Kruglov). - Fix NULL != NULL case for full_sorting_join on LowCardinality(Nullable(T)) column. #92924 (Vladimir Cherkasov).
- Fixed several crashes during merges of text indexes in
MergeTreetables. #92925 (Anton Popov). - Restore LowCardinality wrappers on SET expression results if needed during TTL aggregation to prevent exceptions during table optimization. #92971 (Seva Potapov).
- Fix logical error during index analysis when empty array is used in
hasfunction. Closes #92906. #92995 (Nihal Z. Miaji). - Fix possible hung on terminating background schedule pool (may lead to server hungs on shutdown). #93008 (Azat Khuzhin).
- Fix possible error FILE_DOESNT_EXIST after sparse column mutation when setting
ratio_of_defaults_for_sparse_serializationwas changed to1.0via alter. #93016 (Pavel Kruglov). - Fix bug in data skipping logic when
not materialize(...)ornot CAST(...)is used in WHERE causing incorrect results. Closes #88536. #93017 (Nihal Z. Miaji). - Fix possible usage of outdated parts due to TOCTOU race for shared parts. #93022 (Azat Khuzhin).
- Fix crash when deserialising malformed
groupConcataggregate state with out-of-bounds offsets. #93028 (Raufs Dunamalijevs). - Fix leaving connection in a broken state after preliminary cancellation distributed queries. #93029 (Azat Khuzhin).
- Fix join results when the right-side join key is a sparse column. This closes #92920. I can only reproduce the bug with
set compatibility='23.3'. Not sure if it should be backported. #93038 (Amos Bird). - Fix possible
Cannot finalize buffer after cancellationinestimateCompressionRatio(). Fixes: #87380. #93068 (Azat Khuzhin). - Fixed merges of text indexes built on top of the complex expressions (such as
concat(col1, col2)). #93073 (Anton Popov). - Fix applying projection when filter contains subcolumns. Closes #92882. #93141 (Pavel Kruglov).
- Fix logical error in some cases triggered when join runtime filters are added to query plan. It was caused by incorrectly returning duplicated const columns from one of join sides. #93144 (Alexander Gololobov).
- Special function
__applyFilterused by join runtime filters was returning ILLEGAL_TYPE_OF_ARGUMENT in some valid cases. #93187 (Alexander Gololobov). - Prevent different interpolated columns from collapse into the same column in a block when interpolated columns are effectively aliases of the same column. #93197 (Yakov Olkhovskiy).
- Do not add runtime filter when joining with already filled right table. #93211 (Alexander Gololobov).
- Fix keeper persistent watches cleanup after dead session. This closes #92480. #93213 (Konstantin Vedernikov).
- Fix order by tuple in iceberg. This closes #92977. #93225 (Konstantin Vedernikov).
- Fix bug with S3Queue setting
s3queue_migrate_old_metadata_to_buckets. Closes #93392, #93196, #81739. #93232 (Kseniia Sumarokova). - Remove unused columns when the projection is rebuilt during the merge. It reduces memory usage and creates fewer temporary parts. #93233 (Nikolai Kochetov).
- Fix unused columns removal from subqueries in the presence of a scalar correlated subquery. Before the fix column could have been removed if it was used only in the correlated subquery, and the query would fail with
NOT_FOUND_COLUMN_IN_BLOCKerror. #93273 (Dmitry Novik). - Fix possible missing subcolumn in MV during alter of source table. Closes #93231. #93276 (Pavel Kruglov).
- Fix the
Mergetable engine query planning with the analyzer that could throw ILLEGAL_COLUMN forhostName()when merging local and remote/Distributed tables. Closes #92059. #93286 (Jinlin). - Fixes a case where NOT IN with non-constant array arguments was returning the wrong value + Support for non-constant Array functions. Closes #14980. #93314 (Yarik Briukhovetskyi).
- Fix
Not found columnforuse_top_k_dynamic_filteringoptimization. Fixes #93186. #93316 (Nikolai Kochetov). - Fixed rebuilding of text indexes created on top of subcolumns. #93326 (Anton Popov).
- Fixed handling of empty array as a second argument in
hasAllTokensandhasAnyTokensfunctions. #93328 (Anton Popov). - Fix logical error when runtime filters are used in a query with totals for right side table. #93330 (Alexander Gololobov).
- The server no longer crashes if function
tokensis called with non-const tokenizer parameters (the 2th, 3rd, 4th parameter), e.g.,SELECT tokens(NULL, 1, materialize(1)). #93383 (Robert Schulze). - Fixed integer overflow vulnerability in
groupConcatstate deserialisation that could cause memory safety issues with crafted aggregate states. #93426 (Raufs Dunamalijevs). - Fixed text index analysis on array columns when the index contains no tokens (all arrays are empty or all tokens are skipped by the tokenizer). #93457 (Anton Popov).
- Avoids oauth login in ClickHouse Client when username/password are within the connection string. #93459 (Krishna Mannem).
- Fix Azure ADLS Gen2 vended credentials support in DataLakeCatalog - parse
adls.sas-token.*keys from Iceberg REST catalogs and fix ABFSS URL parsing. #93477 (Karun Anantharaman). - Fix GLOBAL IN support with analyzer (previously set was created on the remote node again). #93507 (Azat Khuzhin).
- Fix extracting subcolumn during deserialization directly into Sparse columns. #93512 (Pavel Kruglov).
- Fixed direct reading from text index with duplicate search queries. #93516 (Anton Popov).
- Fix for NOT_FOUND_COLUMN_IN_BLOCK error when runtime filter is enabled and joined tables have the same column returned multiple times (e.g. SELECT a, a, a FROM t). #93526 (Alexander Gololobov).
- Fix a bug where clickhouse-client would ask for password twice when connecting using ssh. #93547 (Isak Ellmer).
- Make sure that zookeeper is finalized on shutdown (fix possible hung on shutdown in very unlikely cases). #93602 (Azat Khuzhin).
- Fix LOGICAL_ERROR when restoring ReplicatedMergeTree with deduplication race. #93612 (Pablo Marcos).
- Fix using Sparse column for TTL update during direct deserialization into Sparse columns in some input formats. It fixes possible logical error
Unexpected type of result TTL column. #93619 (Pavel Kruglov). - Fixed h3 index functions sometimes crashing or getting stuck when called on invalid inputs. #93657 (Michael Kolupaev).
- The usage of
ngram_bfindex on a non-UTF-8 data led to an uninitialized memory read, with values that could reside in the resulting index structure. Closes #92576. #93663 (Alexey Milovidov). - Validate that the decompressed buffer size is as expected. #93690 (Raúl Marín).
- Prevent users to get the list of columns from a table without checking
SHOW COLUMNSpermission using themergetable engine. #93695 (János Benjamin Antal). - Fixed materialization of skip indexes created on top of subcolumns. #93708 (Anton Popov).
- We store storages' shared pointers in
QueryPipeline::resources::storage_holdersto make sure that theIStorageobjects are not destroyed whilePipelineExecutoris alive. #93746 (Miсhael Stetsyuk). - Fix attaching Replicated DBs when the interserver host changed after restarting. #93779 (Tuan Pham Anh).
- Fix assert
!read_until_positioninReadBufferFromS3which happened when cache is enabled. #93809 (Kseniia Sumarokova). - Fix logical error in a rare case when empty tuple is used with
Mapcolumn. Closes #93784. #93814 (Nihal Z. Miaji). - Fixed
_part_offsetcorruption when projections are rebuilt during merges, and optimized projection processing by avoiding unnecessary reads of the_part_offsetcolumn and skipping unneeded columns in projection calculations. This continues the optimizations introduced in #93233. #93827 (Amos Bird). - Remove 'Bad version' handling. #93843 (Anton Ivashkin).
- Fix
optimize_inverse_dictionary_lookupnot working with distributed query when key is signed integral type. Closes #93259. #93848 (Nihal Z. Miaji). - Fix
lag/leadnot working with distributedremote()query. Closes #90014. #93858 (Nihal Z. Miaji). - Fix system instrument dispatch bug. #93937 (Pablo Marcos).
- In https://github.com/ClickHouse/ClickHouse/pull/89173, we added an extra field to the structure that
TraceSendersends through an internal pipe. However, the buffer size was not updated (here), therefore we are writing more data to buffer thanbuffer_sizewhich results in multiple flushes. And becauseTraceSender::sendis called from different threads, different threads' flushes may interleave which breaks the invariant that the receiving end (TraceCollector) relies on. #93966 (Miсhael Stetsyuk). - Fix type conversion to super type during the join operation of the storage
JoinwithUSINGclause. Fixes #91672. Fixes #78572. #94000 (Dmitry Novik). - Fix for FilterStep not properly added when join runtime filter is applied over Merge table. #94021 (Alexander Gololobov).
- A
SELECTquery containing a predicate on multiple columns with bloom filter skip indexes and bothORandNOTconditions are present could return inconsistent results. That is fixed now. #94026 (Shankar Iyer). - Fix CLEAR column with dependent indices. #94057 (Raúl Marín).
- Fix use-of-uninitialized-value in
ReadWriteBufferFromHTTP. #94058 (Alexey Milovidov). - Fix bad check for typed paths in JSON. The check was introduced in https://github.com/ClickHouse/ClickHouse/pull/92842 and can lead to an error during existing tables startup. #94070 (Pavel Kruglov).
- Fix the crash during filter analysis in the presence of OUTER JOIN. Fixes #90979. #94080 (Dmitry Novik).
- Fix accuracy of
uniqThetawhen using UInt8 aggregation keys in parallel (max_threads> 1 - default). #94095 (Azat Khuzhin). - Fix crash caused by exception thrown from a
socket.setBlocking(true)call insideSCOPE_EXIT. #94100 (Miсhael Stetsyuk). - Fix data loss when
DROP PARTITIONremoves parts created by later log entries in ReplicatedMergeTree. #94123 (Tuan Pham Anh). - Fixed parquet reader v3 incorrectly handling arrays that cross page boundaries. This happens e.g. for files written by Arrow without enabling page statistics or page index. Affects only columns of Array data type. Likely symptom is that one array every ~1 MB of data gets truncated. Before this fix, use this setting as workaround:
input_format_parquet_use_native_reader_v3 = 0. #94125 (Michael Kolupaev). - Fix too many watches in ReplicatedMergeTree while waiting for log entry. #94133 (Azat Khuzhin).
- Functions
arrayShuffle,arrayPartialShuffleandarrayRandomSampleto materialize const columns - so that different rows get different results. #94134 (Joanna Hulboj). - Fix data race in evaluating table functions in materialized views. #94171 (Alexey Milovidov).
- Fix nullptr dereference in
PostgreSQLdatabase engines (when the query is incorrect). Closes #92887. #94180 (Alexey Milovidov). - Fix memory leak in refreshable materialized views using
SELECTqueries with multiple subqueries. #94200 (Antonio Andelic). - Fix data race in
DataPartStorageOnDiskBase::removevssystem.parts. Closes #49076. #94262 (Alexey Milovidov). - Remove the wrong
noexceptspecifier at HashTable copy assignment that may lead to crash (std::terminate) on memory exceptions. #94275 (Nikita Taranov). - Previously, creating a projection with duplicate columns in GROUP BY (e.g.,
GROUP BY c0, c0) and inserting data caused astd::length_errorifoptimize_row_orderis enabled. Closes #94065. #94277 (Alexey Milovidov). - Fix obscure bug in ZooKeeper client on connect which leads to hungs and crashes. #94320 (Azat Khuzhin).
- Fix function to subcolumns optimization not applied to subcolumns. #94323 (Pavel Kruglov).
- Fix possibly incorrect result in nested RIGHT JOINs when
enable_lazy_columns_replicationis enabled. The bug caused all rows in replicated columns to incorrectly return the same value instead of their distinct values. Close #93891. #94339 (Vladimir Cherkasov). - Fix filter pushdown for SEMI JOIN using equivalence sets. Do not push the filter down if argument types have changed. Fixes #93264. #94340 (Dmitry Novik).
- Fix usage of DeltaLake CDF with database DataLake database engine (delta lake catalogs integration). Closes #94122. #94342 (Kseniia Sumarokova).
- Fix incorrect value of current metric
FilesystemCacheSizeLimitin caseSLRUcache policy was used. #94363 (Kseniia Sumarokova). - Creating a Backup database engine with less than two arguments now returns a more descriptive error message (
Wrong number of argumentsinstead ofstd::out_of_range: InlinedVector::at(size_type) const failed bounds check.). #94374 (Robert Schulze). - Ignores impossible revokes of global grants on the database level for grants with grant option. #94386 (pufit).
- Fix reading sparse offsets from compact parts. Closes #94385. #94399 (Pavel Kruglov).
- Don't prevent ALTER of columns using implicit indexes, even if
alter_column_secondary_index_mode'sthrowmode is used. #94425 (Raúl Marín). - Fix crash in
TCPHandlerwhen multiplereceivePacketsExpectQuerycalls readProtocol::Client::IgnoredPartUUIDs. #94434 (Miсhael Stetsyuk). - Fix masking sensitive data in
system.functions. #94436 (Vitaly Baranov). - Fix nullptr dereference with disabled
send_profile_events. This feature was introduced recently for the ClickHouse Python driver. Closes #92488. #94466 (Alexey Milovidov). - Fix text index .mrk incompatibility during merges. #94494 (Peng Jian).
- When
read_in_order_use_virtual_rowis enabled, the code was accessing index columns based on the full primary key size without checking if the index was truncated, leading to use-after-free / uninitialized memory. Closes #85596. #94500 (Alexey Milovidov). - Fix an error due to a type mismatch when sending external tables for subqueries with GLOBAL IN if the types are Nullable. Closes #94097. #94511 (Alexey Milovidov).
- In previous versions, queries with multiple index conditions over the same expression may erroneously throw an exception
Not found column. Closes #60660. #94515 (Alexey Milovidov). - Fix incorrect handling of Nullable join column in runtime filters. #94555 (Alexander Gololobov).
- Creating a workload in another workload that is currently in use no longer causes a crash. #94599 (Sergei Trifonov).
- Fix a crash during ANY LEFT JOIN optimization when
isNotNullis evaluated on a missing column. #94600 (Molly). - Fix default expression evaluation when referencing other columns with computed defaults. #94615 (Alexey Milovidov).
- Fix permission issues in BACKUP/RESTORE operations. #94617 (Pablo Marcos).
- Fix crash due to incorrect type cast when the data type is
Nullable(DateTime64). #94627 (Miсhael Stetsyuk). - Fixes a bug where certain distributed queries with
ORDER BYcould returnALIAScolumns with swapped values (i.e., columnashowing columnb’s data and vice versa). #94644 (filimonov). - Fix storing results of keeper-bench to file. #94654 (Antonio Andelic).
- Fix incorrect estimations with MinMax-type statistics when the column contains negative floating-point values. #94665 (zoomxi).
- Fix reading Parquet files when a map's key is a struct. #94670 (Konstantin Vedernikov).
- Fix possibly incorrect RIGHT join result when using complex ON conditions. Close #92913. #94680 (Vladimir Cherkasov).
- Preserve constant index granularity (use_const_adaptive_granularity) after Vertical merges. #94725 (Azat Khuzhin).
- Fix mutation bug with scalar subqueries and table dependencies. If a table had dependencies (index or projections) over a column, scalar subqueries might be evaluated and cached without data and lead to incorrect changes. #94731 (Raúl Marín).
- Fix AsynchronousMetrics cpu_pressure fallback on error. #94827 (Raúl Marín).
- The
getURLHostRFCfunction was missing bounds checks before dereferencing pointers. When an empty string was passed todomainRFC, it would read uninitialized memory, triggering MSan errors. #94851 (Alexey Milovidov). - Fix readonlyness of encrypted disks. #94852 (Azat Khuzhin).
- Fix logical error in fractional
LIMIT/OFFSETwhen using the old analyzer with Distributed tables. Closes #94712. #94999 (Ahmed Gouda). - Fix crash under some conditions when join runtime filters are enabled by default. #95000 (Alexander Gololobov).
- Improve masking passwords in url used in table engine
URL()and table functionurl(). #95006 (Vitaly Baranov). - Function
toStartOfIntervalnow works in the same way astoStartOfX, whereXisDay, Week, Month, Quarter, Yearwhen theenable_extended_results_for_datetime_functionsis on. #95011 (Kirill Kopnev). - Fix constant string comparisons not respecting the settings
cast_string_to_date_time_mode,bool_true_representation,bool_false_representation, andinput_format_null_as_default. Closes #91681. #95040 (Nihal Z. Miaji). - Fix data race in the filesystem cache. #95064 (Alexey Milovidov).
- Fix a rare race condition in the Parquet reader. #95068 (Alexey Milovidov).
- Fix crash in the top K optimization when
LIMITis zero. Closes #93893. #95072 (Alexey Milovidov). - Converting from DateTime/integers to Time64 extracts the time-of-day component using
toTime, which is not monotonic. TheToDateTimeMonotonicitytemplate incorrectly claimed this conversion was monotonic, causing "Invalid binary search result in MergeTreeSetIndex" exception in debug builds. #95125 (Alexey Milovidov). - Recreated list of manifest file entries only if necessary (previously it was done on each iteration). #95162 (Daniil Ivanik).
Build/Testing/Packaging Improvement
- Add a set of tools for profiling memory allocations in the ClickHouse SQL parser using jemalloc's heap profiling capabilities. #94072 (Ilya Yatsishin).
- Added a tool that simplifies debugging of memory allocations in parser. It uses jemalloc
stats.allocatedmetric before and after we parse query to AST representation to show what is allocated. Also it supports memory profiling mode that dumps profile before and after to build reports where allocations occurred. #93523 (Ilya Yatsishin). - Remove transitive libc++ includes. #92523 (Raúl Marín).
- Make some sequential tests parallel: https://github.com/ClickHouse/ClickHouse/pull/93030/changes#diff-c3a73510dae653c9bbfa24300b32f5d6ec663fd4e72cc4a3d5daa6e4342915df. #93030 (Nikita Fomichev).
- Cleanup some build flags. #93679 (Raúl Marín).
- Bump c-ares from v1.34.5 to v1.34.6. This addresses c-ares'
CVE-2025-62408, which is not relevant for ClickHouse. #94129 (Govind R Nair). - Use
curl8.18.0. #94742 (Konstantin Bogdanov).