mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Fixed BUG#6027: Stored procedures can be renamed.
Removed the support for renaming SPs. It's non-standard, conflicted with a standard syntax, and was a bit broken anyway.
This commit is contained in:
@ -3766,20 +3766,10 @@ purposes internal to the MySQL server", MYF(0));
|
||||
case SQLCOM_ALTER_FUNCTION:
|
||||
{
|
||||
res= -1;
|
||||
uint newname_len= 0;
|
||||
if (lex->name)
|
||||
newname_len= strlen(lex->name);
|
||||
if (newname_len > NAME_LEN)
|
||||
{
|
||||
net_printf(thd, ER_TOO_LONG_IDENT, lex->name);
|
||||
goto error;
|
||||
}
|
||||
if (lex->sql_command == SQLCOM_ALTER_PROCEDURE)
|
||||
res= sp_update_procedure(thd, lex->spname,
|
||||
lex->name, newname_len, &lex->sp_chistics);
|
||||
res= sp_update_procedure(thd, lex->spname, &lex->sp_chistics);
|
||||
else
|
||||
res= sp_update_function(thd, lex->spname,
|
||||
lex->name, newname_len, &lex->sp_chistics);
|
||||
res= sp_update_function(thd, lex->spname, &lex->sp_chistics);
|
||||
switch (res)
|
||||
{
|
||||
case SP_OK:
|
||||
|
Reference in New Issue
Block a user