mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Merge mysql.com:/opt/local/work/mysql-4.1-root
into mysql.com:/opt/local/work/mysql-4.1-9096-fresh sql/item.h: Auto merged sql/item_func.cc: Auto merged
This commit is contained in:
@ -494,3 +494,28 @@ SELECT FOUND_ROWS();
|
||||
FOUND_ROWS()
|
||||
2
|
||||
deallocate prepare stmt;
|
||||
drop table if exists t1;
|
||||
Warnings:
|
||||
Note 1051 Unknown table 't1'
|
||||
create table t1 (c1 int(11) not null, c2 int(11) not null,
|
||||
primary key (c1,c2), key c2 (c2), key c1 (c1));
|
||||
insert into t1 values (200887, 860);
|
||||
insert into t1 values (200887, 200887);
|
||||
select * from t1 where (c1=200887 and c2=200887) or c2=860;
|
||||
c1 c2
|
||||
200887 860
|
||||
200887 200887
|
||||
prepare stmt from
|
||||
"select * from t1 where (c1=200887 and c2=200887) or c2=860";
|
||||
execute stmt;
|
||||
c1 c2
|
||||
200887 860
|
||||
200887 200887
|
||||
prepare stmt from
|
||||
"select * from t1 where (c1=200887 and c2=?) or c2=?";
|
||||
set @a=200887, @b=860;
|
||||
execute stmt using @a, @b;
|
||||
c1 c2
|
||||
200887 860
|
||||
200887 200887
|
||||
deallocate prepare stmt;
|
||||
|
Reference in New Issue
Block a user