-
Notifications
You must be signed in to change notification settings - Fork 549
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Do not filter nulls from fields that are arguments of NON_NULLABLE fu…
…nctions cr> create table t (a int, b int); CREATE OK, 1 row affected (0.210 sec) cr> insert into t values (null, null), (null, 2), (2, null), (2, 2); INSERT OK, 4 rows affected (0.032 sec) cr> select * from t where a != (b||1); +---+---+ | a | b | +---+---+ | 2 | 2 | --> missing a row, see below +---+---+ SELECT 1 row in set (0.022 sec) cr> select a, b, a != (b||1) from t; +------+------+----------------------------+ | a | b | (NOT (a = concat(b, '1'))) | +------+------+----------------------------+ | NULL | 2 | NULL | | NULL | NULL | NULL | | 2 | NULL | TRUE | --> this row is missing from the result of the query above | 2 | 2 | TRUE | because of an unwanted FieldExistsQuery over field 'b' +------+------+----------------------------+ SELECT 4 rows in set (0.023 sec)
- Loading branch information
1 parent
3313662
commit 5ff277c
Showing
3 changed files
with
81 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters