1
0
mirror of https://github.com/MariaDB/server.git synced 2025-11-22 17:44:29 +03:00

Bug #28605: SHOW CREATE VIEW with views using stored_procedures no

longer showing SP names.
SHOW CREATE VIEW uses Item::print() methods to reconstruct the 
statement text from the parse tree.
The print() method for stored procedure calls needs allocate 
space to print the function's quoted name.
It was incorrectly calculating the length of the buffer needed 
(was too short).
Fixed to reflect the actual space needed.
This commit is contained in:
gkodinov/kgeorge@magare.gmz
2007-05-29 14:45:30 +03:00
parent 48fe280271
commit a6ebd63479
3 changed files with 34 additions and 2 deletions

View File

@@ -6152,3 +6152,14 @@ count(*)
3
drop table t1,t2;
drop function bug27354;
CREATE TABLE t1 (a INT);
INSERT INTO t1 VALUES (1),(2);
CREATE FUNCTION metered(a INT) RETURNS INT RETURN 12;
CREATE VIEW v1 AS SELECT test.metered(a) as metered FROM t1;
SHOW CREATE VIEW v1;
View Create View
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `test`.`metered`(`t1`.`a`) AS `metered` from `t1`
DROP VIEW v1;
DROP FUNCTION metered;
DROP TABLE t1;
End of 5.0 tests