Bug #26570 CHECK TABLE not allowed in PSs
Submitted: 22 Feb 2007 15:02 Modified: 26 Feb 2007 15:21
Reporter: Max Mether Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Prepared statements Severity:S4 (Feature request)
Version:5,1.14/5.1BK OS:Linux (Linux)
Assigned to: CPU Architecture:Any
Triage: D5 (Feature request)

[22 Feb 2007 15:02] Max Mether
Description:
Lots of statements have been added to Prepared Statements in 5.1 (See bug 20655, http://bugs.mysql.com/bug.php?id=20665). 

However the CHECK TABLE statement has been completely forgotten, eventhough it's allowed in SPs. Also note that OPTIMZE TABLE and REPAIR TABLE are allowed in PSs. 

How to repeat:
mysql> PREPARE stm FROM 'CHECK TABLE City';
ERROR 1295: This command is not supported in the prepared statement protocol yet
[22 Feb 2007 15:32] Miguel Solorzano
Thank you for the bug report.
[26 Feb 2007 15:21] Konstantin Osipov
Thank you for a feature request.
The task of Bug#20665 was to make sure that all statements supported in Stored Procedures are also supported in Prepared Statements. There was a disparity that has been removed.

CHECK TABLE is not allowed in Stored Procedures:

mysql> create procedure p1() begin check table t1; end//
ERROR 1314 (0A000): CHECK is not allowed in stored procedures
[7 Mar 2007 23:19] Konstantin Osipov
Bug#26877 was marked a duplicate of this bug.