summaryrefslogtreecommitdiff
path: root/mysql-test/t/sp-code.test
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.org>2017-08-18 18:29:33 +0400
committerAlexander Barkov <bar@mariadb.org>2017-08-18 18:29:33 +0400
commit4305c3ca5797ba4157384c363579be8e934e2fb1 (patch)
treeaa48de35235e7d087d385f3c28edeacdf11e9d89 /mysql-test/t/sp-code.test
parenta70809c0fcd5eca38c5f6bafa92270f1704a0597 (diff)
downloadmariadb-git-4305c3ca5797ba4157384c363579be8e934e2fb1.tar.gz
MDEV-13581 ROW TYPE OF t1 and t1%ROWTYPE for routine parameters
Diffstat (limited to 'mysql-test/t/sp-code.test')
-rw-r--r--mysql-test/t/sp-code.test24
1 files changed, 24 insertions, 0 deletions
diff --git a/mysql-test/t/sp-code.test b/mysql-test/t/sp-code.test
index d4b63a73920..29b6764ebc6 100644
--- a/mysql-test/t/sp-code.test
+++ b/mysql-test/t/sp-code.test
@@ -734,3 +734,27 @@ DROP PROCEDURE testp_bug11763507;
DROP FUNCTION testf_bug11763507;
--echo #END OF BUG#11763507 test.
+
+
+--echo #
+--echo # MDEV-13581 ROW TYPE OF t1 and t1%ROWTYPE for routine parameters
+--echo #
+
+CREATE TABLE t1 (a INT, b TEXT);
+DELIMITER $$;
+CREATE PROCEDURE p1(a ROW TYPE OF t1, OUT b ROW TYPE OF t1)
+BEGIN
+ SET a.a = 100;
+ SET a.b = 'aaa';
+ SET b.a = 200;
+ SET b.b = 'bbb';
+ SET a = b;
+ SET b = a;
+ SET a.a = b.a;
+ SET b.a = a.a;
+END;
+$$
+DELIMITER ;$$
+SHOW PROCEDURE CODE p1;
+DROP PROCEDURE p1;
+DROP TABLE t1;