when drop a table, TABLE_STATISTICS not clean it.
Bug #1449440 reported by
rj03hou
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS | Status tracked in 5.7 | |||||
5.5 |
Triaged
|
Medium
|
Unassigned | |||
5.6 |
Triaged
|
Medium
|
Unassigned | |||
5.7 |
Triaged
|
Medium
|
Unassigned |
Bug Description
rt, I think is easy to fix it.
tags: | added: userstat |
To post a comment you must log in.
This is really easy to confirm:
[openxs@centos ~]$ mysql -uroot test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.6.23-72.1-log Percona Server (GPL), Release 72.1, Revision 0503478
Copyright (c) 2009-2015 Percona LLC and/or its affiliates
Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> show variables like 'userstat'; ------- --+---- ---+ ------- --+---- ---+ ------- --+---- ---+
+------
| Variable_name | Value |
+------
| userstat | OFF |
+------
1 row in set (0.00 sec)
mysql> set global userstat=ON;
Query OK, 0 rows affected (0.00 sec)
mysql> show variables like 'userstat'; ------- --+---- ---+ ------- --+---- ---+ ------- --+---- ---+
+------
| Variable_name | Value |
+------
| userstat | ON |
+------
1 row in set (0.00 sec)
mysql> create table tu(id int primary key);
Query OK, 0 rows affected (0.23 sec)
mysql> insert into tu values(1),(2),(3);
Query OK, 3 rows affected (0.06 sec)
Records: 3 Duplicates: 0 Warnings: 0
mysql> select * from information_ schema. table_statistic s\G ******* ******* ****** 1. row ******* ******* ******* ******
TABLE_ SCHEMA: test
TABLE_ NAME: tu
ROWS_ READ: 0
ROWS_ CHANGED: 3 X_INDEXES: 3
*******
ROWS_CHANGED_
1 row in set (0.00 sec)
mysql> drop table tu;
Query OK, 0 rows affected (0.05 sec)
mysql> select * from information_ schema. table_statistic s\G ******* ******* ****** 1. row ******* ******* ******* ******
TABLE_ SCHEMA: test
TABLE_ NAME: tu
ROWS_ READ: 0
ROWS_ CHANGED: 3 X_INDEXES: 3
*******
ROWS_CHANGED_
1 row in set (0.00 sec)