diff options
author | unknown <kostja@bodhi.(none)> | 2008-04-17 01:04:49 +0400 |
---|---|---|
committer | unknown <kostja@bodhi.(none)> | 2008-04-17 01:04:49 +0400 |
commit | bd2a73281243ad5c9f190e4fa17b752e41c11f3d (patch) | |
tree | 004ae389135211061cc92ab42ed47cde54656931 /sql/table.h | |
parent | 1ff9a2437a5a7ecd5d6b8bb409fa473613f14460 (diff) | |
download | mariadb-git-bd2a73281243ad5c9f190e4fa17b752e41c11f3d.tar.gz |
WL#4165 "Prepared statements: validation".
Add metadata validation to ~20 more SQL commands. Make sure that
these commands actually work in ps-protocol, since until now they
were enabled, but not carefully tested.
Fixes the ml003 bug found by Matthias during internal testing of the
patch.
mysql-test/r/ps_ddl.result:
Update test results (WL#4165)
mysql-test/t/ps_ddl.test:
Cover with tests metadata validation of 26 SQL statements.
sql/mysql_priv.h:
Fix the name in the comment.
sql/sp_head.cc:
Changed the way the observer is removed in case of stored procedures
to support validation prepare stmt from "call p1(<expr>)": whereas
tables used in the expression must be validated, substatements
of p1 must not.
The previous scheme used to silence the observer only in stored
functions and triggers.
sql/sql_class.cc:
Now the observer is silenced in sp_head::execute(). Remove it from
Sub_statement_state.
sql/sql_class.h:
Now the observer is silenced in sp_head::execute(). Remove it from
Sub_statement_state.
sql/sql_parse.cc:
Add CF_REEXECUTION_FRAGILE to 20 more SQLCOMs that need it.
sql/sql_prepare.cc:
Add metadata validation to ~20 new SQLCOMs that need it.
Fix memory leaks with expressions used in SHOW DATABASES and CALL
(and prepared statements).
We need to fix all expressions at prepare, since if these expressions
use subqueries, there are one-time transformations of the parse
tree that must be done at prepare.
List of fixed commands includes: SHOW TABLES, SHOW DATABASES,
SHOW TRIGGERS, SHOW EVENTS, SHOW OPEN TABLES,SHOW KEYS, SHOW FIELDS,
SHOW COLLATIONS, SHOW CHARSETS, SHOW VARIABLES, SHOW TATUS, SHOW TABLE
STATUS, SHOW PROCEDURE STATUS, SHOW FUNCTION STATUS, CALL.
Add comment to set_parameters().
sql/table.h:
Update comments.
Diffstat (limited to 'sql/table.h')
-rw-r--r-- | sql/table.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/table.h b/sql/table.h index 2b3c9b8d5b1..603557fee78 100644 --- a/sql/table.h +++ b/sql/table.h @@ -1336,7 +1336,7 @@ struct TABLE_LIST (if any) with values obtained from the current table definition cache element. - @sa check_and_update_metadata_version() + @sa check_and_update_table_version() */ inline bool is_metadata_version_equal(TABLE_SHARE *s) const @@ -1349,7 +1349,7 @@ struct TABLE_LIST Record the value of metadata version of the corresponding table definition cache element in this parse tree node. - @sa check_and_update_metadata_version() + @sa check_and_update_table_version() */ inline void set_metadata_version(TABLE_SHARE *s) |