mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Merge mysql.com:/extern/mysql/5.1/generic/mysql-5.0-merge
into mysql.com:/extern/mysql/5.1/generic/mysql-5.1-new mysql-test/r/innodb.result: Auto merged mysql-test/r/sp.result: Auto merged mysql-test/r/timezone_grant.result: Auto merged mysql-test/r/trigger.result: Auto merged mysql-test/r/view.result: Auto merged mysql-test/t/innodb.test: Auto merged mysql-test/t/sp.test: Auto merged mysql-test/t/trigger.test: Auto merged mysql-test/t/view.test: Auto merged sql/lex.h: Auto merged sql/sp.cc: Auto merged sql/sp_head.cc: Auto merged sql/sp_head.h: Auto merged sql/sql_class.cc: Auto merged sql/sql_view.cc: Auto merged mysql-test/r/rpl_insert_id.result: Manual merge. mysql-test/t/disabled.def: Manual merge. mysql-test/t/rpl_insert_id.test: Manual merge. sql/item_func.cc: Manual merge. sql/sql_yacc.yy: Manual merge - not complete yet.
This commit is contained in:
@@ -2074,7 +2074,7 @@ void THD::restore_backup_open_tables_state(Open_tables_state *backup)
|
||||
The following things is done
|
||||
- Disable binary logging for the duration of the statement
|
||||
- Disable multi-result-sets for the duration of the statement
|
||||
- Value of last_insert_id() is reset and restored
|
||||
- Value of last_insert_id() is saved and restored
|
||||
- Value set by 'SET INSERT_ID=#' is reset and restored
|
||||
- Value for found_rows() is reset and restored
|
||||
- examined_row_count is added to the total
|
||||
@@ -2086,6 +2086,8 @@ void THD::restore_backup_open_tables_state(Open_tables_state *backup)
|
||||
We reset examined_row_count and cuted_fields and add these to the
|
||||
result to ensure that if we have a bug that would reset these within
|
||||
a function, we are not loosing any rows from the main statement.
|
||||
|
||||
We do not reset value of last_insert_id().
|
||||
****************************************************************************/
|
||||
|
||||
void THD::reset_sub_statement_state(Sub_statement_state *backup,
|
||||
@@ -2112,7 +2114,6 @@ void THD::reset_sub_statement_state(Sub_statement_state *backup,
|
||||
/* Disable result sets */
|
||||
client_capabilities &= ~CLIENT_MULTI_RESULTS;
|
||||
in_sub_stmt|= new_state;
|
||||
last_insert_id= 0;
|
||||
next_insert_id= 0;
|
||||
insert_id_used= 0;
|
||||
examined_row_count= 0;
|
||||
|
||||
Reference in New Issue
Block a user