diff options
author | unknown <serg@serg.mylan> | 2003-07-30 16:15:10 +0200 |
---|---|---|
committer | unknown <serg@serg.mylan> | 2003-07-30 16:15:10 +0200 |
commit | 20e39672fb84d3ce70ff466713b84f7d9c78c7fe (patch) | |
tree | d4ef00706641ad95046bde9a8bfea353f329f7ac /myisam | |
parent | 2763b52d0a0ad85818f5c8259b4dd1d060e568e7 (diff) | |
download | mariadb-git-20e39672fb84d3ce70ff466713b84f7d9c78c7fe.tar.gz |
Bug#937
myisamchk.c:
help text clarified
mi_check.c:
allow one to "analyze" empty table :)
myisam/mi_check.c:
allow one to "analyze" empty table :)
myisam/myisamchk.c:
help text clarified
Diffstat (limited to 'myisam')
-rw-r--r-- | myisam/mi_check.c | 11 | ||||
-rw-r--r-- | myisam/myisamchk.c | 10 |
2 files changed, 13 insertions, 8 deletions
diff --git a/myisam/mi_check.c b/myisam/mi_check.c index 6caacd95386..4b28a88fc6e 100644 --- a/myisam/mi_check.c +++ b/myisam/mi_check.c @@ -3562,11 +3562,12 @@ int update_state_info(MI_CHECK *param, MI_INFO *info,uint update) uint i, key_parts= mi_uint2korr(share->state.header.key_parts); share->state.rec_per_key_rows=info->state->records; share->state.changed&= ~STATE_NOT_ANALYZED; - for (i=0; i<key_parts; i++) - { - if (!(share->state.rec_per_key_part[i]=param->rec_per_key_part[i])) - share->state.changed|= STATE_NOT_ANALYZED; - } + if (info->state->records) + for (i=0; i<key_parts; i++) + { + if (!(share->state.rec_per_key_part[i]=param->rec_per_key_part[i])) + share->state.changed|= STATE_NOT_ANALYZED; + } } if (update & (UPDATE_STAT | UPDATE_SORT | UPDATE_TIME | UPDATE_AUTO_INC)) { diff --git a/myisam/myisamchk.c b/myisam/myisamchk.c index 882f868e326..1a27e9debe8 100644 --- a/myisam/myisamchk.c +++ b/myisam/myisamchk.c @@ -357,11 +357,15 @@ static void usage(void) -e, --extend-check Check the table VERY throughly. Only use this in\n\ extreme cases as myisamchk should normally be able to\n\ find out if the table is ok even without this switch\n\ - -F, --fast Check only tables that haven't been closed properly\n\ - -C, --check-only-changed\n\ - Check only tables that have changed since last check\n\ + -F, --fast Check only tables that haven't been closed properly.\n\ + It also applies to other requested actions (e.g. --analyze\n\ + will be ignored if the table is already analyzed).\n\ -f, --force Restart with '-r' if there are any errors in the table.\n\ States will be updated as with '--update-state'\n\ + -C, --check-only-changed\n\ + Check only tables that have changed since last check.\n\ + It also applies to other requested actions (e.g. --analyze\n\ + will be ignored if the table is already analyzed).\n\ -i, --information Print statistics information about table that is checked\n\ -m, --medium-check Faster than extend-check, but only finds 99.99% of\n\ all errors. Should be good enough for most cases\n\ |