1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

A preparatory patch to help adding JOIN::transform() and move one-time

query transformations to the PREPARE stage (prepared statements).


sql/item.h:
  Remove an unused friend declaration.
sql/mysql_priv.h:
  Change signature of insert_fields()
sql/sp_head.cc:
  Make is_stmt_prepare_or_first_sp_execute really work: reset SP state
  to EXECUTED after execution.
sql/sql_base.cc:
  allocate_view_names flag of insert_fields is removed.
  The purpose of this variable was to amend the case when a view
  is replaced with a base table between subsequent executions of a prepared
  statement: in that case the new table theoretically can be used instead
  of the view. If allocate_view_names was set,
  all the references to the view expressions were replaced with Item_field's
  which in turn could have been resolved by their names.
  But this approach doesn't work for other reasons, so let's not try
  to help what must be solved by TDC.
sql/sql_class.h:
  Add is_first_sp_execute() helper method.
sql/sql_handler.cc:
  insert_fields signature changed.
sql/sql_lex.h:
  Add a comment for variable 'first_execution'.
This commit is contained in:
unknown
2005-06-21 21:15:21 +04:00
parent e85b001321
commit 04f6f63dd8
7 changed files with 20 additions and 31 deletions

View File

@ -422,7 +422,7 @@ bool mysql_ha_read(THD *thd, TABLE_LIST *tables,
}
}
if (insert_fields(thd, tables, tables->db, tables->alias, &it, 0, 0))
if (insert_fields(thd, tables, tables->db, tables->alias, &it, 0))
goto err0;
protocol->send_fields(&list, Protocol::SEND_NUM_ROWS | Protocol::SEND_EOF);