diff options
author | unknown <igor@olga.mysql.com> | 2007-04-11 11:41:12 -0700 |
---|---|---|
committer | unknown <igor@olga.mysql.com> | 2007-04-11 11:41:12 -0700 |
commit | aa051961c9ac4629fd7dca9f236172e47660bbeb (patch) | |
tree | 88f41dabdbfaba464324807134b6d577f5b0403c /mysql-test/t/row.test | |
parent | 2911bcd8e39735931f2dc095770c24bb6350d378 (diff) | |
download | mariadb-git-aa051961c9ac4629fd7dca9f236172e47660bbeb.tar.gz |
Fixed bug #27484: a crash when incompatible row expressions with nested rows
are used as arguments of the IN predicate.
Added a function to check compatibility of row expressions. Made sure that this
function to be called for Item_func_in objects by fix_length_and_dec().
mysql-test/r/row.result:
Added a test case for bug #27484.
mysql-test/t/row.test:
Added a test case for bug #27484.
Diffstat (limited to 'mysql-test/t/row.test')
-rw-r--r-- | mysql-test/t/row.test | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/mysql-test/t/row.test b/mysql-test/t/row.test index d8d9a244134..6c66d45b942 100644 --- a/mysql-test/t/row.test +++ b/mysql-test/t/row.test @@ -83,4 +83,29 @@ drop table t1; SELECT ROW(2,10) <=> ROW(3,4); SELECT ROW(NULL,10) <=> ROW(3,NULL); +# +# Bug #27484: nested row expressions in IN predicate +# + +--error 1241 +SELECT ROW(1,ROW(2,3)) IN (ROW(1,ROW(2,3)),ROW(1,1)); +--error 1241 +SELECT ROW(1,ROW(2,3)) IN (ROW(1,ROW(2,3)),ROW(1,1),ROW(1,ROW(2,3))); +--error 1241 +SELECT ROW(1,ROW(2,3)) IN (ROW(1,ROW(2,3)),ROW(1,ROW(2,2,2))); +--error 1241 +SELECT ROW(1,ROW(2,3,4)) IN (ROW(1,ROW(2,3,4)),ROW(1,ROW(2,2))); + +--error 1241 +SELECT ROW(1,ROW(2,3)) IN (ROW(1,ROW(2,3)),(SELECT 1,1)); +--error 1241 +SELECT ROW(1,ROW(2,3)) IN (ROW(1,ROW(2,3)),(SELECT 1,1),ROW(1,ROW(2,4))); +--error 1241 +SELECT ROW(1,ROW(2,3)) IN ((SELECT 1,1),ROW(1,ROW(2,3))); + +--error 1241 +SELECT ROW(2,1) IN (ROW(21,2),ROW(ROW(1,1,3),0)); +--error 1241 +SELECT ROW(2,1) IN (ROW(ROW(1,1,3),0),ROW(21,2)); + # End of 4.1 tests |