Alexey Kopytov
453107bc56
Bug #54190 : Comparison to row subquery produces incorrect
...
result
Row subqueries producing no rows were not handled as UNKNOWN
values in row comparison expressions.
That was a result of the following two problems:
1. Item_singlerow_subselect did not mark the resulting row
value as NULL/UNKNOWN when no rows were produced.
2. Arg_comparator::compare_row() did not take into account that
a whole argument may be NULL rather than just individual scalar
values.
Before bug#34384 was fixed, the above problems were hidden
because an uninitialized (i.e. without any stored value) cached
object would appear as NULL for scalar values in a row subquery
returning an empty result. After the fix
Arg_comparator::compare_row() would try to evaluate
uninitialized cached objects.
Fixed by removing the aforementioned problems.
mysql-test/r/row.result:
Added a test case for bug #54190 .
mysql-test/r/subselect.result:
Updated the result for a test relying on wrong behavior.
mysql-test/t/row.test:
Added a test case for bug #54190 .
sql/item_cmpfunc.cc:
If either of the argument rows is NULL, return NULL as the
result of comparison.
sql/item_subselect.cc:
Adjust null_value for Item_singlerow_subselect depending on
whether a row has been produced by the row subquery.
2010-09-09 16:46:13 +04:00
..
2010-05-24 21:54:08 +08:00
2009-12-18 14:00:30 +02:00
2009-10-30 11:40:44 +02:00
2010-03-25 23:57:06 +04:00
2010-02-09 11:30:50 +01:00
2010-02-25 23:13:11 +04:00
2010-05-28 00:07:40 +04:00
2010-02-02 14:17:21 +02:00
2010-04-22 15:52:00 +02:00
2009-11-25 12:25:49 +05:30
2009-10-27 12:09:19 +04:00
2010-07-20 14:36:15 -03:00
2010-03-09 07:36:26 -03:00
2009-12-22 13:52:23 +04:00
2010-05-24 21:54:08 +08:00
2010-01-16 15:44:24 +08:00
2010-03-09 16:09:32 +01:00
2010-05-24 21:54:08 +08:00
2010-03-22 16:27:59 +04:00
2010-04-06 12:26:59 +05:00
2009-12-03 13:22:34 +04:00
2010-02-17 16:13:42 +04:00
2009-11-18 13:49:45 +01:00
2010-08-31 02:16:38 +04:00
2010-06-24 15:21:23 +02:00
2010-05-19 11:18:59 +02:00
2010-05-29 22:16:45 +04:00
2010-05-24 21:54:08 +08:00
2009-12-22 17:52:15 +02:00
2010-03-25 16:08:21 +04:00
2010-04-03 00:30:22 +04:00
2010-07-23 15:52:54 +04:00
2010-08-27 13:44:35 +04:00
2010-06-22 22:53:08 +04:00
2010-06-08 10:22:40 +04:00
2010-06-20 02:02:58 +04:00
2010-08-01 22:12:36 +04:00
2010-08-13 16:05:46 +03:00
2010-03-26 09:49:35 +04:00
2010-08-13 16:05:46 +03:00
2010-03-25 15:49:01 +04:00
2010-08-30 11:51:46 +04:00
2009-10-29 22:06:10 -07:00
2009-10-20 11:47:57 +05:30
2009-10-27 12:09:19 +04:00
2010-05-04 17:03:28 +03:00
2010-07-30 16:35:06 +03:00
2010-06-11 09:38:29 +02:00
2010-06-09 14:45:04 +04:00
2010-07-09 14:39:47 +04:00
2010-06-25 12:01:47 +04:00
2010-05-28 00:07:40 +04:00
2010-08-09 13:39:59 +02:00
2010-06-01 11:54:06 +04:00
2010-04-27 00:46:52 +04:00
2010-07-14 14:54:51 +03:00
2009-10-19 13:44:44 +05:00
2010-05-28 00:07:40 +04:00
2010-05-12 13:19:12 +02:00
2010-02-26 09:22:48 -03:00
2009-10-27 12:09:19 +04:00
2010-07-21 18:05:57 +03:00
2010-06-25 15:59:44 +03:00
2010-03-19 10:01:02 +04:00
2010-03-12 10:33:16 +04:00
2010-05-24 21:54:08 +08:00
2009-10-14 16:26:16 +05:00
2010-03-25 16:11:16 +04:00
2010-07-30 09:17:10 -03:00
2010-07-01 12:05:09 +03:00
2009-12-17 12:06:36 -08:00
2010-03-22 13:10:18 +01:00
2010-03-28 19:57:33 +08:00
2010-05-07 00:41:37 +04:00
2010-06-03 10:31:26 +02:00
2010-06-03 10:31:26 +02:00
2010-08-04 10:52:45 +02:00
2010-02-05 17:51:55 +00:00
2009-11-06 17:54:19 +03:00
2010-01-29 16:54:27 +02:00
2009-12-10 17:38:01 +02:00
2010-05-07 00:41:37 +04:00
2009-12-13 23:29:50 +03:00
2010-02-01 16:07:00 +01:00
2010-05-25 15:41:00 +02:00
2010-03-12 11:52:38 +01:00
2010-07-08 14:36:55 +02:00
2010-03-12 11:52:38 +01:00
2010-08-11 14:13:59 +02:00
2010-03-22 16:30:27 +04:00
2010-03-13 18:32:42 -03:00
2010-01-16 15:44:24 +08:00
2009-10-27 14:09:36 +04:00
2010-04-30 15:27:17 +04:00
2010-03-24 17:37:41 +01:00
2009-11-03 17:18:43 +01:00
2010-08-24 19:51:32 +04:00
2010-05-21 22:47:32 +04:00
2010-09-09 16:46:13 +04:00
2010-06-26 19:36:00 +02:00
2010-06-24 12:00:48 +04:00
2010-02-09 11:30:50 +01:00
2010-03-31 16:12:37 +03:00
2010-02-05 13:39:46 +04:00
2010-01-12 15:16:26 +01:00
2010-05-24 21:54:08 +08:00
2010-02-09 11:30:50 +01:00
2010-02-13 08:35:14 -02:00
2009-11-21 09:18:21 -02:00
2010-02-09 11:30:50 +01:00
2009-11-27 18:10:28 +02:00
2009-12-02 15:17:08 +04:00
2010-02-09 11:30:50 +01:00
2010-03-09 07:36:26 -03:00
2010-08-05 12:42:14 +02:00
2010-09-09 16:46:13 +04:00
2010-04-01 18:49:02 +04:00
2009-10-27 14:09:36 +04:00
2010-08-18 12:56:06 +08:00
2010-02-16 13:13:49 +04:00
2010-02-09 11:30:50 +01:00
2010-03-16 10:20:07 +01:00
2010-03-09 07:36:26 -03:00
2009-11-20 12:10:47 +02:00
2010-05-31 13:25:11 +04:00
2010-02-09 11:30:50 +01:00
2010-03-22 12:33:25 +04:00
2010-03-18 11:26:27 +01:00
2010-03-09 07:36:26 -03:00
2010-07-19 11:03:52 +02:00
2010-05-21 22:47:32 +04:00
2009-12-22 14:38:33 +04:00
2010-02-11 14:26:58 +01:00
2010-05-20 10:31:03 +04:00
2010-06-04 17:10:22 +03:00
2010-03-09 07:36:26 -03:00
2010-02-12 00:54:14 -02:00
2010-04-06 12:26:59 +05:00
2010-02-09 11:30:50 +01:00
2010-03-10 19:31:22 +04:00