Below is the list of changes that have just been committed into a local
5.0 repository of kostja. When kostja does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.1824 05/04/13 12:30:30 konstantin@stripped +3 -0
Allow SQLCOM_CALL in prepared mode.
sql/sql_prepare.cc
1.111 05/04/13 12:30:22 konstantin@stripped +1 -0
Allow SQLCOM_CALL in prepared mode.
mysql-test/t/ps.test
1.35 05/04/13 12:30:22 konstantin@stripped +26 -0
Adding tests for CALL statement in prepared mode.
mysql-test/r/ps.result
1.36 05/04/13 12:30:21 konstantin@stripped +28 -0
Test results: adding tests for CALL statement in prepared mode.
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: konstantin
# Host: dragonfly.local
# Root: /home/kostja/work/mysql-5.0-root
--- 1.35/mysql-test/r/ps.result 2005-04-05 04:09:51 -07:00
+++ 1.36/mysql-test/r/ps.result 2005-04-13 12:30:21 -07:00
@@ -542,3 +542,31 @@
COUNT(*)
37
deallocate prepare my_stmt;
+drop procedure if exists p1|
+drop table if exists t1|
+create table t1 (id int)|
+insert into t1 values(1)|
+create procedure p1(a int, b int)
+begin
+declare c int;
+select max(id)+1 into c from t1;
+insert into t1 select a+b;
+insert into t1 select a-b;
+insert into t1 select a-c;
+end|
+set @a= 3, @b= 4|
+prepare stmt from "call p1(?, ?)"|
+execute stmt using @a, @b|
+execute stmt using @a, @b|
+select * from t1|
+id
+1
+7
+-1
+1
+7
+-1
+-5
+deallocate prepare stmt|
+drop procedure p1|
+drop table t1|
--- 1.34/mysql-test/t/ps.test 2005-04-05 04:09:51 -07:00
+++ 1.35/mysql-test/t/ps.test 2005-04-13 12:30:22 -07:00
@@ -561,3 +561,29 @@
dec $exec_loop_count;
}
deallocate prepare my_stmt;
+
+# Test CALL in prepared mode
+delimiter |;
+--disable_warnings
+drop procedure if exists p1|
+drop table if exists t1|
+--enable_warnings
+create table t1 (id int)|
+insert into t1 values(1)|
+create procedure p1(a int, b int)
+begin
+ declare c int;
+ select max(id)+1 into c from t1;
+ insert into t1 select a+b;
+ insert into t1 select a-b;
+ insert into t1 select a-c;
+end|
+set @a= 3, @b= 4|
+prepare stmt from "call p1(?, ?)"|
+execute stmt using @a, @b|
+execute stmt using @a, @b|
+select * from t1|
+deallocate prepare stmt|
+drop procedure p1|
+drop table t1|
+delimiter ;|
--- 1.110/sql/sql_prepare.cc 2005-04-01 02:02:22 -08:00
+++ 1.111/sql/sql_prepare.cc 2005-04-13 12:30:22 -07:00
@@ -1654,6 +1654,7 @@
case SQLCOM_DROP_INDEX:
case SQLCOM_ROLLBACK:
case SQLCOM_TRUNCATE:
+ case SQLCOM_CALL:
break;
default:
| Thread |
|---|
| • bk commit into 5.0 tree (konstantin:1.1824) | konstantin | 13 Apr |