Fix bug lp:858038
Analysis: The cause of the bug was the changed meaning of subselect_partial_match_engine::has_covering_null_row. Previously it meant that there is row with NULLs in all nullable fields of the materialized subquery table. Later it was changed to mean a row with NULLs in all fields of this table. At the same time there was a shortcut in subselect_rowid_merge_engine::partial_match() that detected a special case where: - there is no match in any of the columns with NULLs, and - there is no NULL-only row that covers all columns with NULLs. With the change in the meaning of has_covering_null_row, the condition that detected this special case was incomplete. This resulted in an incorrect FALSE, when the result was a partial match. Solution: Expand the condition that detected the special case with the correct test for the existence of a row with NULL values in all columns that contain NULLs (a kind of parially covering NULL-row).
Showing
Please register or sign in to comment