Use the OPTIMIZE TABLE statement to remove all free space from a table and organize the data more efficiently.
ON ClauseThe ON clause is optional and specifies the name of an index in the table to use for organizing the physical data records. It is usually recommended that you do not specify this clause, which will result in the table being organized using the primary index.
NOBACKUP ClauseThe NOBACKUP clause specifies that no backup files should be created during the process of optimizing the table.
The statement below optimizes a table and suppresses any backup files: