From e34496e5d827c774a92891fb8201a53a27564e38 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 10 Aug 2006 22:55:20 +0800 Subject: BUG#19914 SELECT COUNT(*) sometimes returns MAX_INT on cluster tables allow handler::info to return an error code (that will be returned to the user) sql/ha_berkeley.cc: update handler::info interface to return int sql/ha_berkeley.h: update handler::info interface to return int sql/ha_heap.cc: update handler::info interface to return int sql/ha_heap.h: update handler::info interface to return int sql/ha_innodb.cc: update handler::info interface to return int sql/ha_innodb.h: update handler::info interface to return int sql/ha_myisam.cc: update handler::info interface to return int sql/examples/ha_archive.cc: update handler::info interface to return int sql/examples/ha_archive.h: update handler::info interface to return int sql/examples/ha_example.cc: update handler::info interface to return int sql/examples/ha_example.h: update handler::info interface to return int sql/examples/ha_tina.cc: update handler::info interface to return int sql/examples/ha_tina.h: update handler::info interface to return int sql/ha_myisam.h: update handler::info interface to return int sql/ha_myisammrg.cc: update handler::info interface to return int sql/ha_myisammrg.h: update handler::info interface to return int sql/ha_ndbcluster.cc: update handler::info interface to return int sql/ha_ndbcluster.h: update handler::info interface to return int sql/handler.h: update handler::info interface to return int sql/opt_sum.cc: If we get an error when using handler::info to get count(*), print and return the error. sql/sql_select.cc: if error, set fatal error. --- sql/ha_myisammrg.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sql/ha_myisammrg.h') diff --git a/sql/ha_myisammrg.h b/sql/ha_myisammrg.h index 7348096b695..84eaae04590 100644 --- a/sql/ha_myisammrg.h +++ b/sql/ha_myisammrg.h @@ -71,7 +71,7 @@ class ha_myisammrg: public handler int rnd_pos(byte * buf, byte *pos); void position(const byte *record); ha_rows records_in_range(uint inx, key_range *min_key, key_range *max_key); - void info(uint); + int info(uint); int extra(enum ha_extra_function operation); int extra_opt(enum ha_extra_function operation, ulong cache_size); int external_lock(THD *thd, int lock_type); -- cgit v1.2.1