1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

After merge fixes

Add support for warnings for prepare of prepared statements
Fixed test to work with --ps-protocol
Fixed some test results


libmysql/libmysql.c:
  Add support for warnings for prepare of prepared statements
mysql-test/r/func_concat.result:
  After merge fixes
mysql-test/r/select.result:
  Delete conflicting tables form previous tests
mysql-test/r/view.result:
  New code from 4.1 fixed old error
mysql-test/t/create.test:
  Ensure that --ps-protocol return same results as normal test
mysql-test/t/func_group.test:
  Remove not needed --disable_ps_protocol
mysql-test/t/func_time.test:
  Ensure that --ps-protocol return same results as normal test
mysql-test/t/having.test:
  Ensure that --ps-protocol return same results as normal test
mysql-test/t/insert_select.test:
  Remove not needed --disable_ps_protocol
mysql-test/t/select.test:
  Ensure that --ps-protocol return same results as normal test
mysql-test/t/sp.test:
  Fixed comment
mysql-test/t/system_mysql_db_fix.test:
  Fix that results is same as from system_mysql_db.test
mysql-test/t/trigger.test:
  Added comment
mysql-test/t/type_blob.test:
  Remove not needed --disable_ps_protocol
mysql-test/t/union.test:
  Run most of the test with --ps-protocol
mysql-test/t/user_limits.test:
  Ensure that --ps-protocol return same results as normal test
mysql-test/t/view.test:
  Removed --error as bug is now fixed
mysql-test/t/warnings.test:
  Ensure that --ps-protocol return same results as normal test
ndb/include/Makefile.am:
  Don't automaticly use SCCS files
sql/ha_ndbcluster.cc:
  Removed compiler warning
sql/log_event.cc:
  After merge fix
sql/sql_class.h:
  After merge fix
sql/sql_insert.cc:
  After merge fix
sql/sql_load.cc:
  After merge fix
sql/sql_prepare.cc:
  Add support for warnings for prepare of prepared statements
sql/sql_update.cc:
  After merge fixes
This commit is contained in:
unknown
2005-01-04 13:46:53 +02:00
parent 6d0443331a
commit bd365f7622
26 changed files with 91 additions and 49 deletions

View File

@@ -283,7 +283,7 @@ bool mysql_insert(THD *thd,TABLE_LIST *table_list,
to NULL.
*/
thd->count_cuted_fields= ((values_list.elements == 1 &&
duplic != DUP_IGNORE) ?
!ignore) ?
CHECK_FIELD_ERROR_FOR_NULL :
CHECK_FIELD_WARN);
thd->cuted_fields = 0L;
@@ -306,7 +306,7 @@ bool mysql_insert(THD *thd,TABLE_LIST *table_list,
table->file->start_bulk_insert(values_list.elements);
thd->no_trans_update= 0;
thd->abort_on_warning= (duplic != DUP_IGNORE &&
thd->abort_on_warning= (!ignore &&
(thd->variables.sql_mode &
(MODE_STRICT_TRANS_TABLES |
MODE_STRICT_ALL_TABLES)));
@@ -1758,7 +1758,8 @@ bool mysql_insert_select_prepare(THD *thd)
select_insert::select_insert(TABLE_LIST *table_list_par, TABLE *table_par,
List<Item> *fields_par,
List<Item> *update_fields, List<Item> *update_values,
List<Item> *update_fields,
List<Item> *update_values,
enum_duplicates duplic,
bool ignore_check_option_errors)
:table_list(table_list_par), table(table_par), fields(fields_par),
@@ -1805,12 +1806,11 @@ select_insert::prepare(List<Item> &values, SELECT_LEX_UNIT *u)
restore_record(table,default_values); // Get empty record
table->next_number_field=table->found_next_number_field;
thd->cuted_fields=0;
if (info.ignore ||
info.handle_duplicates == DUP_REPLACE)
if (info.ignore || info.handle_duplicates == DUP_REPLACE)
table->file->extra(HA_EXTRA_IGNORE_DUP_KEY);
table->file->start_bulk_insert((ha_rows) 0);
thd->no_trans_update= 0;
thd->abort_on_warning= (info.handle_duplicates != DUP_IGNORE &&
thd->abort_on_warning= (!info.ignore &&
(thd->variables.sql_mode &
(MODE_STRICT_TRANS_TABLES |
MODE_STRICT_ALL_TABLES)));
@@ -1856,9 +1856,7 @@ bool select_insert::send_data(List<Item> &values)
DBUG_RETURN(1);
if (table_list) // Not CREATE ... SELECT
{
switch (table_list->view_check_option(thd,
thd->lex->duplicates ==
DUP_IGNORE)) {
switch (table_list->view_check_option(thd, info.ignore)) {
case VIEW_CHECK_SKIP:
DBUG_RETURN(0);
case VIEW_CHECK_ERROR:
@@ -2010,12 +2008,11 @@ select_create::prepare(List<Item> &values, SELECT_LEX_UNIT *u)
restore_record(table,default_values); // Get empty record
thd->cuted_fields=0;
if (info.ignore ||
info.handle_duplicates == DUP_REPLACE)
if (info.ignore || info.handle_duplicates == DUP_REPLACE)
table->file->extra(HA_EXTRA_IGNORE_DUP_KEY);
table->file->start_bulk_insert((ha_rows) 0);
thd->no_trans_update= 0;
thd->abort_on_warning= (info.handle_duplicates != DUP_IGNORE &&
thd->abort_on_warning= (!info.ignore &&
(thd->variables.sql_mode &
(MODE_STRICT_TRANS_TABLES |
MODE_STRICT_ALL_TABLES)));