Repository navigation
Fix QCC write by topK query with split AND-chain filters - #112083
Conversation
|
Workflow [PR], commit [2a72b52] Summary: ✅
AI ReviewSummaryThis PR propagates the query condition cache key to every split Final Verdict✅ No blocking or major issues found. LLVM Coverage Report
Changed lines: Changed C/C++ lines covered: 4/4 (100.00%) · Uncovered code |
LLVM Coverage Report
Changed lines: Changed C/C++ lines covered: 4/4 (100.00%) · Uncovered code |
|
@alexey-milovidov After this fix, setting |
Query condition cache entries are keyed by (table UUID, part name, condition hash), so a background merge landing between the priming and the reusing query replaces the parts and the second run reads zero hits. Add `SYSTEM STOP MERGES` right after each `CREATE TABLE` to make the hit counts stable in CI. Co-Authored-By: Claude Fable 5 <[email protected]>
Ref : https://github.com/ClickHouse/clickhouse-private/issues/65449
topK queries in following structure were not updating the QCC during execution. Hence QCC pruning for these queries was nil.
FilterStep::transformPipelinesplits a conjunctiveWHEREinto oneFilterTransformper atom, but only the residual transform was given the query condition cache condition. A granule fully eliminated by any earlier atom was therefore never recorded: that atom has no condition to write under, and its empty chunk, which carries theMarkRangesInfoidentifying the granule, is dropped byskip_empty_chunksbefore it reaches the residual. Pass the condition to every atom - the chain is conjunctive, so a chunk emptied at any atom proves no row of those mark ranges can satisfy the wholeand(...).Changelog category
Changelog entry
WHEREclause with multipleANDconditions.