Skip to content

Conversation

@raghunandanbhat
Copy link
Contributor

Fixes - MDEV-38487

Problem

When building a pushable condition that can be pushed from HAVING into WHERE, the server tries to clone aggregate functions. This is not necessary because aggregate functions can not be pushed into WHERE anyway.

Fix

This fix introduces a check within Item::build_pushable_cond to skip cloning aggregate functions.

Also fixes assert failure in MDEV-38492, by adding a missing copy method for Item_aggregate_ref.

…to WHERE

Problem:
  When building a pushable condition that can be pushed from HAVING into
  WHERE, the server tries to clone aggregate functions. This is not
  necessary because aggregate functions can not be pushed into WHERE
  anyway.

Fix:
  This fix introduces a check within `Item::build_pushable_cond` to skip
  cloning aggregate functions.

Also fixes assert failure in MDEV-38492, by adding a missing copy method
for `Item_aggregate_ref`.
@sanja-byelkin sanja-byelkin enabled auto-merge (rebase) January 20, 2026 08:29
@sanja-byelkin sanja-byelkin merged commit a847142 into 10.6 Jan 20, 2026
12 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants