1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Fixed bug in multiple-table-delete where some rows was not deleted

mysql-test/r/delete.result:
  Test case for bug in multiple-table-delete where some rows was not deleted
mysql-test/t/delete.test:
  Test case for bug in multiple-table-delete where some rows was not deleted
sql/item_subselect.cc:
  Code cleanup
sql/opt_range.cc:
  Code cleanup
sql/sql_delete.cc:
  Fixed bug in multiple-table-delete where some rows was not deleted
  This happend when the first table-to-delete-from was not the the table that was scanned.
  Fixed this by only doing 'delete-on-the-fly' for the first table.
  Fixed also some wrong error handling in multi-table-delete
This commit is contained in:
unknown
2005-05-30 20:48:40 +03:00
parent 6a7dedf259
commit e2285c541b
6 changed files with 97 additions and 48 deletions

View File

@ -1854,7 +1854,8 @@ class multi_delete :public select_result_interceptor
ha_rows deleted, found;
uint num_of_tables;
int error;
bool do_delete, transactional_tables, normal_tables;
bool do_delete, transactional_tables, normal_tables, delete_while_scanning;
public:
multi_delete(THD *thd, TABLE_LIST *dt, uint num_of_tables);
~multi_delete();
@ -1862,7 +1863,7 @@ public:
bool send_data(List<Item> &items);
bool initialize_tables (JOIN *join);
void send_error(uint errcode,const char *err);
int do_deletes (bool from_send_error);
int do_deletes();
bool send_eof();
};