diff options
author | unknown <jimw@rama.(none)> | 2006-08-02 19:48:12 -0700 |
---|---|---|
committer | unknown <jimw@rama.(none)> | 2006-08-02 19:48:12 -0700 |
commit | 7f69aee4ea2b0cf07cf2e960bd82c565d8ce0b25 (patch) | |
tree | 062bd3302b325e625299de3dd4ee3a0b2a8079bc /client | |
parent | 10ee3a50fcd4d26a95ab8e88a8871167c265a6bb (diff) | |
parent | c4bfacd7770c5b55c81caec16bc58687f8d974e1 (diff) | |
download | mariadb-git-7f69aee4ea2b0cf07cf2e960bd82c565d8ce0b25.tar.gz |
Merge bk-internal:/home/bk/mysql-5.0-maint
into rama.(none):/home/jimw/my/mysql-5.0-16502
Diffstat (limited to 'client')
-rw-r--r-- | client/mysqlcheck.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/client/mysqlcheck.c b/client/mysqlcheck.c index 804fa14956f..5d87a4fd23c 100644 --- a/client/mysqlcheck.c +++ b/client/mysqlcheck.c @@ -458,7 +458,7 @@ static int process_all_tables_in_db(char *database) LINT_INIT(res); if (use_db(database)) return 1; - if (mysql_query(sock, "SHOW TABLES") || + if (mysql_query(sock, "SHOW TABLE STATUS") || !((res= mysql_store_result(sock)))) return 1; @@ -484,8 +484,12 @@ static int process_all_tables_in_db(char *database) } for (end = tables + 1; (row = mysql_fetch_row(res)) ;) { - end= fix_table_name(end, row[0]); - *end++= ','; + /* Skip tables with an engine of NULL (probably a view). */ + if (row[1]) + { + end= fix_table_name(end, row[0]); + *end++= ','; + } } *--end = 0; if (tot_length) @@ -495,7 +499,11 @@ static int process_all_tables_in_db(char *database) else { while ((row = mysql_fetch_row(res))) - handle_request_for_tables(row[0], strlen(row[0])); + /* Skip tables with an engine of NULL (probably a view). */ + if (row[1]) + { + handle_request_for_tables(row[0], strlen(row[0])); + } } mysql_free_result(res); return 0; |