diff options
author | Sergey Petrunya <psergey@askmonty.org> | 2012-06-20 15:01:28 +0400 |
---|---|---|
committer | Sergey Petrunya <psergey@askmonty.org> | 2012-06-20 15:01:28 +0400 |
commit | 8c762965d389dcd9e74c743aaf2a89bd8c18545f (patch) | |
tree | a266816b7b2a7e5f2266fa46b7b8627aa5543773 /mysql-test/r/ps.result | |
parent | 0b93b444b6c4de6b219fd3a4b3d5fa2e388dc211 (diff) | |
parent | 584d923c3292395a2e8288adcf4795992789f27c (diff) | |
download | mariadb-git-8c762965d389dcd9e74c743aaf2a89bd8c18545f.tar.gz |
Merge 5.3 -> 5.5
Diffstat (limited to 'mysql-test/r/ps.result')
-rw-r--r-- | mysql-test/r/ps.result | 65 |
1 files changed, 61 insertions, 4 deletions
diff --git a/mysql-test/r/ps.result b/mysql-test/r/ps.result index 82a944cc81b..7629775b892 100644 --- a/mysql-test/r/ps.result +++ b/mysql-test/r/ps.result @@ -255,15 +255,15 @@ deallocate prepare StMt1; deallocate prepare Stmt1; ERROR HY000: Unknown prepared statement handler (Stmt1) given to DEALLOCATE PREPARE set names utf8; -prepare `ü` from 'select 1234'; -execute `ü` ; +prepare `ü` from 'select 1234'; +execute `ü` ; 1234 1234 set names latin1; -execute `ü`; +execute `ü`; 1234 1234 -deallocate prepare `ü`; +deallocate prepare `ü`; set names default; create table t1 (a varchar(10)) charset=utf8; insert into t1 (a) values ('yahoo'); @@ -3055,6 +3055,62 @@ DEALLOCATE PREPARE stmt; DROP TABLE t1; End of 5.1 tests. +# +# LP bug#1001500 Crash on the second execution of the PS for +# a query with degenerated conjunctive condition +# (see also mysql bug#12582849) +# +CREATE TABLE t1 ( +pk INTEGER AUTO_INCREMENT, +col_int_nokey INTEGER, +col_int_key INTEGER, +col_varchar_key VARCHAR(1), +col_varchar_nokey VARCHAR(1), +PRIMARY KEY (pk), +KEY (col_int_key), +KEY (col_varchar_key, col_int_key) +); +INSERT INTO t1 ( +col_int_key, col_int_nokey, +col_varchar_key, col_varchar_nokey +) VALUES +(4, 2, 'v', 'v'), +(62, 150, 'v', 'v'); +CREATE TABLE t2 ( +pk INTEGER AUTO_INCREMENT, +col_int_nokey INTEGER, +col_int_key INTEGER, +col_varchar_key VARCHAR(1), +col_varchar_nokey VARCHAR(1), +PRIMARY KEY (pk), +KEY (col_int_key), +KEY (col_varchar_key, col_int_key) +); +INSERT INTO t2 ( +col_int_key, col_int_nokey, +col_varchar_key, col_varchar_nokey +) VALUES +(8, NULL, 'x', 'x'), +(7, 8, 'd', 'd'); +PREPARE stmt FROM ' +SELECT + ( SELECT MAX( SQ1_alias2 .col_int_nokey ) AS SQ1_field1 + FROM ( t2 AS SQ1_alias1 RIGHT JOIN t1 AS SQ1_alias2 + ON ( SQ1_alias2.col_varchar_key = SQ1_alias1.col_varchar_nokey ) + ) + WHERE SQ1_alias2.pk < alias1.col_int_nokey OR alias1.pk + ) AS field1 +FROM ( t1 AS alias1 JOIN t2 AS alias2 ON alias2.pk ) +GROUP BY field1 +'; +EXECUTE stmt; +field1 +150 +EXECUTE stmt; +field1 +150 +DEALLOCATE PREPARE stmt; +DROP TABLE t1, t2; # # WL#4435: Support OUT-parameters in prepared statements. @@ -4044,3 +4100,4 @@ c1 c2 count(c3) 2012-03-01 01:00:00 3 1 2012-03-01 02:00:00 3 1 DEALLOCATE PREPARE s1; +# End of 5.3 tests |