diff options
author | unknown <bell@sanja.is.com.ua> | 2002-12-06 00:40:28 +0200 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2002-12-06 00:40:28 +0200 |
commit | f67abe26fbadc52a14621a627c999e563b38bc8f (patch) | |
tree | bbdab3cd51ac1e8b7d77d92c2541b96f9447eeb4 /sql/sql_analyse.cc | |
parent | ef4f5b2148e3120033725f56470d87686612a637 (diff) | |
download | mariadb-git-f67abe26fbadc52a14621a627c999e563b38bc8f.tar.gz |
fixed bug of PROCEDURE in same query with subselects
prohibited using procedure inside subquery
fixed error handling of procedure analize
mysql-test/r/subselect.result:
test of PROCEDURE in subselect
test of PROCEDURE of subselect
mysql-test/t/subselect.test:
test of PROCEDURE in subselect
test of PROCEDURE of subselect
sql/sql_analyse.cc:
fixed error handling in procedure analize
sql/sql_parse.cc:
fixed bug of PROCEDURE in same query with subselects
sql/sql_yacc.yy:
prohibited using procedure inside subquery
Diffstat (limited to 'sql/sql_analyse.cc')
-rw-r--r-- | sql/sql_analyse.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/sql_analyse.cc b/sql/sql_analyse.cc index f98eb0e0b26..ac641f64b53 100644 --- a/sql/sql_analyse.cc +++ b/sql/sql_analyse.cc @@ -89,21 +89,21 @@ proc_analyse_init(THD *thd, ORDER *param, select_result *result, if ((*param->item)->type() != Item::INT_ITEM || (*param->item)->val() < 0) { - net_printf(thd, ER_WRONG_PARAMETERS_TO_PROCEDURE, proc_name); + my_error(ER_WRONG_PARAMETERS_TO_PROCEDURE, MYF(0), proc_name); DBUG_RETURN(0); } pc->max_tree_elements = (uint) (*param->item)->val_int(); param = param->next; if (param->next) // no third parameter possible { - net_printf(thd, ER_WRONG_PARAMCOUNT_TO_PROCEDURE, proc_name); + my_error(ER_WRONG_PARAMCOUNT_TO_PROCEDURE, MYF(0), proc_name); DBUG_RETURN(0); } // second parameter if ((*param->item)->type() != Item::INT_ITEM || (*param->item)->val() < 0) { - net_printf(thd, ER_WRONG_PARAMETERS_TO_PROCEDURE, proc_name); + my_error(ER_WRONG_PARAMETERS_TO_PROCEDURE, MYF(0), proc_name); DBUG_RETURN(0); } pc->max_treemem = (uint) (*param->item)->val_int(); @@ -111,7 +111,7 @@ proc_analyse_init(THD *thd, ORDER *param, select_result *result, else if ((*param->item)->type() != Item::INT_ITEM || (*param->item)->val() < 0) { - net_printf(thd, ER_WRONG_PARAMETERS_TO_PROCEDURE, proc_name); + my_error(ER_WRONG_PARAMETERS_TO_PROCEDURE, MYF(0), proc_name); DBUG_RETURN(0); } // if only one parameter was given, it will be the value of max_tree_elements |