summaryrefslogtreecommitdiff
path: root/sql/ha_innodb.cc
diff options
context:
space:
mode:
authorunknown <heikki@hundin.mysql.fi>2003-04-24 15:34:43 +0300
committerunknown <heikki@hundin.mysql.fi>2003-04-24 15:34:43 +0300
commit1e8414803c0e3583ec729954236c3498d739d26a (patch)
treee9f2a3c82363f345c8c2e5c14bbea6edf4c8ea81 /sql/ha_innodb.cc
parentcdf3e090e5d1cd9a0aaf17dba52acf39abdfe1a1 (diff)
downloadmariadb-git-1e8414803c0e3583ec729954236c3498d739d26a.tar.gz
ha_innodb.h, ha_innodb.cc:
Make ANALYZE TABLE to update index cardinality and other statistics also for an InnoDB table; note that the estimates are based on 10 random dives, not on an exhaustive read of the table sql/ha_innodb.cc: Make ANALYZE TABLE to update index cardinality and other statistics also for an InnoDB table; note that the estimates are based on 10 random dives, not on an exhaustive read of the table sql/ha_innodb.h: Make ANALYZE TABLE to update index cardinality and other statistics also for an InnoDB table; note that the estimates are based on 10 random dives, not on an exhaustive read of the table
Diffstat (limited to 'sql/ha_innodb.cc')
-rw-r--r--sql/ha_innodb.cc17
1 files changed, 17 insertions, 0 deletions
diff --git a/sql/ha_innodb.cc b/sql/ha_innodb.cc
index 5cd8a285d0c..8d682deb583 100644
--- a/sql/ha_innodb.cc
+++ b/sql/ha_innodb.cc
@@ -3756,6 +3756,23 @@ ha_innobase::info(
DBUG_VOID_RETURN;
}
+/**************************************************************************
+Updates index cardinalities of the table, based on 10 random dives into
+each index tree. This does NOT calculate exact statistics of the table. */
+
+int
+ha_innobase::analyze(
+/*=================*/
+ /* out: returns always 0 (success) */
+ THD* thd, /* in: connection thread handle */
+ HA_CHECK_OPT* check_opt) /* in: currently ignored */
+{
+ /* Simply call ::info() with all the flags */
+ info(HA_STATUS_TIME | HA_STATUS_CONST | HA_STATUS_VARIABLE);
+
+ return(0);
+}
+
/***********************************************************************
Tries to check that an InnoDB table is not corrupted. If corruption is
noticed, prints to stderr information about it. In case of corruption