From c40a424a055a46f36a98691eec051b1966772376 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 28 Mar 2001 04:16:04 +0300 Subject: Let ALTER TABLE and LOAD DATA INFILE use sorting to create index Call init_signals before intializing table handlers. This should fix the signal problem in Innobase on Solaris Docs/manual.texi: Updated changelog include/myisam.h: Let ALTER TABLE and LOAD DATA INFILE use sorting to create index myisam/mi_check.c: Let ALTER TABLE and LOAD DATA INFILE use sorting to create index myisam/myisamchk.c: Let ALTER TABLE and LOAD DATA INFILE use sorting to create index sql/ha_myisam.cc: Let ALTER TABLE and LOAD DATA INFILE use sorting to create index sql/mysqld.cc: Call init_signals before intializing table handlers. This should fix the signal problem in Innobase on Solaris --- sql/ha_myisam.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'sql/ha_myisam.cc') diff --git a/sql/ha_myisam.cc b/sql/ha_myisam.cc index af35c0269c4..1a205e54b9d 100644 --- a/sql/ha_myisam.cc +++ b/sql/ha_myisam.cc @@ -544,8 +544,10 @@ int ha_myisam::repair(THD *thd, MI_CHECK ¶m, bool optimize) (!param.opt_rep_quick || !(share->state.changed & STATE_NOT_OPTIMIZED_KEYS)))) { - optimize_done=1; - if (mi_test_if_sort_rep(file,file->state->records,0) && + ulonglong key_map= ((param.testflag & T_CREATE_MISSING_KEYS) ? + ((ulonglong) 1L << share->base.keys)-1 : + share->state.key_map); + if (mi_test_if_sort_rep(file,file->state->records,key_map,0) && (param.testflag & T_REP_BY_SORT)) { uint testflag=param.testflag; @@ -646,7 +648,6 @@ bool ha_myisam::activate_all_index(THD *thd) param.sort_buffer_length= myisam_sort_buffer_size; param.opt_rep_quick++; // Don't copy data file param.tmpdir=mysql_tmpdir; - error=repair(thd,param,0) != HA_ADMIN_OK; thd->proc_info=save_proc_info; } -- cgit v1.2.1