• Sergei Petrunia's avatar
    MDEV-8988: Apparently valid SQL query gives wrong result (nested WHERE) · b05158cc
    Sergei Petrunia authored
    - "Early NULLs filtering" optimization used to "peel off" Item_ref and
      Item_direct_ref wrappers from an outside column reference before
      adding "outer_table_col IS NOT NULL" into JOIN::outer_ref_cond.
    - When this happened in a subquery that was evaluated in a post-GROUP-BY
      context, attempt to evaluate JOIN::outer_ref_cond would fetch an
      incorrect value of outer_table_col.
    b05158cc
group_by.test 58.8 KB