Which of these best reduces the size of a large InnoDB table's file after deleting many rows?
- A DELETE with a WHERE clause
- B OPTIMIZE TABLE
- C FLUSH TABLES
- D ANALYZE TABLE
Answer
OPTIMIZE TABLE
DELETE marks pages reusable but does not shrink the tablespace file. OPTIMIZE TABLE rebuilds the table and reclaims the space.





