CHECK TABLE table_name[,table_name,...] [options]
Description: Checks a table for errors, the equivalent of myisamchk -m table_name, and updates the key statistics on the table. Returns a resultset showing the status after running the command.
options can be any number of the following, separated by spaces if more than one is specified:
QUICK— Does not scan rows for wrong links
FAST— Only checks tables that have not been closed properly
CHANGED— Only checks tables that have not been closed properly or that have been changed since the last check
MEDIUM— Scans rows to verify that deleted links are okay
EXTENDED— Does a full key lookup for all keys on each row
Limitations: MyISAM and InnoDB tables
Description in: Day 16
See also: REPAIR TABLE
Get Sams Teach Yourself MySQL in 21 Days, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.