diff options
author | unknown <monty@donna.mysql.com> | 2000-08-21 03:00:52 +0300 |
---|---|---|
committer | unknown <monty@donna.mysql.com> | 2000-08-21 03:00:52 +0300 |
commit | 55c5016f92383fdf7cd14de4ef3ec5afbb89fd5a (patch) | |
tree | f46edbbf41f400440bde25519820b29885305b1b /myisam | |
parent | 259c7ea0f84f25d82ec7b818e5b770f0bc7917d3 (diff) | |
download | mariadb-git-55c5016f92383fdf7cd14de4ef3ec5afbb89fd5a.tar.gz |
RENAME TABLE table_name TO new_table_name ; Faster Alloc
Small bug fixes
myisammrg/myrg_rfirst.c:
Change mode to -rw-rw-r--
myisammrg/myrg_rlast.c:
Change mode to -rw-rw-r--
myisammrg/myrg_rnext.c:
Change mode to -rw-rw-r--
myisammrg/myrg_rprev.c:
Change mode to -rw-rw-r--
Docs/manual.texi:
Update of RENAME
configure.in:
Portability fix
include/global.h:
Fix for ODBC and Intel Ia64
include/mysqld_error.h:
RENAME TABLE
myisam/myisamchk.c:
Faster --fast
myisammrg/myrg_queue.c:
Bug fix
myisammrg/myrg_rkey.c:
Portability fix
sql-bench/test-insert.sh:
Fix for duplicate key test
sql/ChangeLog:
Changelog
sql/Makefile.am:
RENAME TABLE
sql/item_sum.cc:
Fix for COUNT(DISTINCT)
sql/lock.cc:
RENAME TABLE
sql/share/czech/errmsg.sys:
RENAME TABLE
sql/share/czech/errmsg.txt:
RENAME TABLE
sql/share/danish/errmsg.sys:
RENAME TABLE
sql/share/danish/errmsg.txt:
RENAME TABLE
sql/share/dutch/errmsg.sys:
RENAME TABLE
sql/share/dutch/errmsg.txt:
RENAME TABLE
sql/share/english/errmsg.sys:
RENAME TABLE
sql/share/english/errmsg.txt:
RENAME TABLE
sql/share/estonia/errmsg.sys:
RENAME TABLE
sql/share/estonia/errmsg.txt:
RENAME TABLE
sql/share/french/errmsg.sys:
RENAME TABLE
sql/share/french/errmsg.txt:
RENAME TABLE
sql/share/german/errmsg.sys:
RENAME TABLE
sql/share/german/errmsg.txt:
RENAME TABLE
sql/share/greek/errmsg.sys:
RENAME TABLE
sql/share/greek/errmsg.txt:
RENAME TABLE
sql/share/hungarian/errmsg.sys:
RENAME TABLE
sql/share/hungarian/errmsg.txt:
RENAME TABLE
sql/share/italian/errmsg.sys:
RENAME TABLE
sql/share/italian/errmsg.txt:
RENAME TABLE
sql/share/japanese/errmsg.sys:
RENAME TABLE
sql/share/japanese/errmsg.txt:
RENAME TABLE
sql/share/korean/errmsg.sys:
RENAME TABLE
sql/share/korean/errmsg.txt:
RENAME TABLE
sql/share/norwegian-ny/errmsg.txt:
RENAME TABLE
sql/share/norwegian/errmsg.txt:
RENAME TABLE
sql/share/polish/errmsg.sys:
RENAME TABLE
sql/share/polish/errmsg.txt:
RENAME TABLE
sql/share/portuguese/errmsg.sys:
RENAME TABLE
sql/share/portuguese/errmsg.txt:
RENAME TABLE
sql/share/romania/errmsg.sys:
RENAME TABLE
sql/share/romania/errmsg.txt:
RENAME TABLE
sql/share/romanian/errmsg.txt:
***MISSING WEAVE***
sql/share/russian/errmsg.sys:
RENAME TABLE
sql/share/russian/errmsg.txt:
RENAME TABLE
sql/share/slovak/errmsg.sys:
RENAME TABLE
sql/share/slovak/errmsg.txt:
RENAME TABLE
sql/share/spanish/errmsg.sys:
RENAME TABLE
sql/share/spanish/errmsg.txt:
RENAME TABLE
sql/share/swedish/errmsg.OLD:
RENAME TABLE
sql/share/swedish/errmsg.sys:
RENAME TABLE
sql/share/swedish/errmsg.txt:
RENAME TABLE
sql/slave.cc:
Faster alloc
sql/sql_base.cc:
RENAME TABLE
sql/sql_class.cc:
Faster alloc
sql/sql_class.h:
Faster alloc
sql/sql_insert.cc:
Fix bug in INSERT ... SELECT to BDB table
sql/sql_lex.h:
RENAME TABLE
sql/sql_select.cc:
Faster alloc
sql/sql_show.cc:
Faster alloc
sql/sql_table.cc:
RENAME TABLE
sql/sql_yacc.yy:
RENAME TABLE
sql/thr_malloc.cc:
Faster alloc
sql/unireg.h:
RENAME TABLE
strings/ctype-sjis.c:
Portability fix
Diffstat (limited to 'myisam')
-rw-r--r-- | myisam/myisamchk.c | 48 |
1 files changed, 34 insertions, 14 deletions
diff --git a/myisam/myisamchk.c b/myisam/myisamchk.c index abfb580b501..5740dcf76f5 100644 --- a/myisam/myisamchk.c +++ b/myisam/myisamchk.c @@ -190,7 +190,7 @@ static struct option long_options[] = static void print_version(void) { - printf("%s Ver 1.29 for %s at %s\n",my_progname,SYSTEM_TYPE, + printf("%s Ver 1.30 for %s at %s\n",my_progname,SYSTEM_TYPE, MACHINE_TYPE); } @@ -295,7 +295,7 @@ static void get_options(register int *argc,register char ***argv) set_all_changeable_vars(changeable_vars); if (isatty(fileno(stdout))) check_param.testflag|=T_WRITE_LOOP; - while ((c=getopt_long(*argc,*argv,"acCdeif?lqrmosSTuUvVw#:b:D:k:O:R:A::t:", + while ((c=getopt_long(*argc,*argv,"acCdeifF?lqrmosSTuUvVw#:b:D:k:O:R:A::t:", long_options, &option_index)) != EOF) { switch(c) { @@ -520,22 +520,42 @@ static int myisamchk(MI_CHECK *param, my_string filename) We are using --fast and the table is closed properly We are using --check-only-changed-tables and the table hasn't changed */ - if (((param->testflag & T_CHECK_ONLY_CHANGED) && - (share->state.changed & (STATE_CHANGED | STATE_CRASHED | - STATE_CRASHED_ON_REPAIR))) || - (param->testflag & T_FAST) && share->state.open_count == 0) + if (param->testflag & (T_FAST | T_CHECK_ONLY_CHANGED)) { - if (!(param->testflag & T_SILENT) || param->testflag & T_INFO) - printf("MyISAM file: %s is already checked\n",filename); - if (mi_close(info)) + my_bool need_to_check= mi_is_crashed(info) || share->state.open_count != 0; + + if ((param->testflag & (T_REP_BY_SORT | T_REP | T_SORT_RECORDS)) && + ((share->state.changed & (STATE_CHANGED | STATE_CRASHED | + STATE_CRASHED_ON_REPAIR) || + !(param->testflag & T_CHECK_ONLY_CHANGED)))) + need_to_check=1; + + if ((param->testflag & T_STATISTICS) && + (share->state.changed & STATE_NOT_ANALYZED)) + need_to_check=1; + if ((param->testflag & T_SORT_INDEX) && + (share->state.changed & STATE_NOT_SORTED_PAGES)) + need_to_check=1; + if ((param->testflag & T_REP_BY_SORT) && + (share->state.changed & STATE_NOT_OPTIMIZED_KEYS)) + need_to_check=1; + if ((param->testflag & T_CHECK_ONLY_CHANGED) && + (share->state.changed & (STATE_CHANGED | STATE_CRASHED | + STATE_CRASHED_ON_REPAIR))) + need_to_check=1; + if (!need_to_check) { - mi_check_print_error(param,"%d when closing MyISAM-table '%s'", - my_errno,filename); - DBUG_RETURN(1); + if (!(param->testflag & T_SILENT) || param->testflag & T_INFO) + printf("MyISAM file: %s is already checked\n",filename); + if (mi_close(info)) + { + mi_check_print_error(param,"%d when closing MyISAM-table '%s'", + my_errno,filename); + DBUG_RETURN(1); + } + DBUG_RETURN(0); } - DBUG_RETURN(0); } - if ((param->testflag & (T_REP_BY_SORT | T_REP | T_STATISTICS | T_SORT_RECORDS | T_SORT_INDEX)) && (((param->testflag & T_UNPACK) && |