Bug #59595 | CHECK TABLES on a VIEW appears to take the time that it does to run the query | ||
---|---|---|---|
Submitted: | 18 Jan 2011 20:49 | Modified: | 10 Mar 2015 15:44 |
Reporter: | Jaimie Sirovich | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | MySQL Server: Views | Severity: | S2 (Serious) |
Version: | 5.1.50, 5.1.56 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[18 Jan 2011 20:49]
Jaimie Sirovich
[19 Jan 2011 4:13]
Valeriy Kravchuk
Thank you for the problem report. Indeed, looks like CHECK TABLE execute SELECT for the view without any additional limitations: macbook-pro:5.1 openxs$ bin/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 7 Server version: 5.1.56-debug Source distribution Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL v2 license Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> create view v1 as select sleep(20) as a from mysql.user; Query OK, 0 rows affected (0.04 sec) mysql> select * from v1; +---+ | a | +---+ | 0 | | 0 | | 0 | | 0 | | 0 | +---+ 5 rows in set (1 min 40.00 sec) mysql> select * from v1 limit 0; Empty set (0.00 sec) mysql> check table v1 fast; +---------+-------+----------+----------+ | Table | Op | Msg_type | Msg_text | +---------+-------+----------+----------+ | test.v1 | check | status | OK | +---------+-------+----------+----------+ 1 row in set (1 min 40.00 sec)
[10 Mar 2015 15:44]
Erlend Dahl
We can't repeat this on 5.6.