diff options
author | unknown <monty@donna.mysql.fi> | 2001-03-28 04:16:04 +0300 |
---|---|---|
committer | unknown <monty@donna.mysql.fi> | 2001-03-28 04:16:04 +0300 |
commit | f176ef0ae70295b68cc08a539f78295b2b38dea0 (patch) | |
tree | 38b2247ef713d4674800dd1b3bd02090dd25c35f /myisam | |
parent | 475c3d52a9a8459d0e98769900ff345fc42fde88 (diff) | |
download | mariadb-git-f176ef0ae70295b68cc08a539f78295b2b38dea0.tar.gz |
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
Diffstat (limited to 'myisam')
-rw-r--r-- | myisam/mi_check.c | 10 | ||||
-rw-r--r-- | myisam/myisamchk.c | 1 |
2 files changed, 9 insertions, 2 deletions
diff --git a/myisam/mi_check.c b/myisam/mi_check.c index 4bd6747d499..64fbafca022 100644 --- a/myisam/mi_check.c +++ b/myisam/mi_check.c @@ -3166,12 +3166,18 @@ void mi_disable_non_unique_index(MI_INFO *info, ha_rows rows) */ my_bool mi_test_if_sort_rep(MI_INFO *info, ha_rows rows, + ulonglong key_map, my_bool force) { MYISAM_SHARE *share=info->s; - uint i; MI_KEYDEF *key=share->keyinfo; - if (!share->state.key_map) + uint i; + + /* + repair_by_sort only works if we have at least one key. If we don't + have any keys, we should use the normal repair. + */ + if (!key_map) return FALSE; /* Can't use sort */ for (i=0 ; i < share->base.keys ; i++,key++) { diff --git a/myisam/myisamchk.c b/myisam/myisamchk.c index 220040fcc0a..cbdd6a26767 100644 --- a/myisam/myisamchk.c +++ b/myisam/myisamchk.c @@ -693,6 +693,7 @@ static int myisamchk(MI_CHECK *param, my_string filename) (share->state.key_map || (rep_quick && !param->keys_in_use && !recreate)) && mi_test_if_sort_rep(info, info->state->records, + info->s->state.key_map, check_param.force_sort)) { error=mi_repair_by_sort(&check_param,info,fixed_name,rep_quick); |