Repair Table
REPAIR TABLE is mainly for MyISAM tables that got corrupted. InnoDB almost never wants REPAIR TABLE — you use dump/restore or innodb recovery settings instead.
If a teacher’s old lab uses MyISAM and SELECT crashes, they may show REPAIR TABLE t; Don’t make it your default InnoDB answer.
Trap — REPAIR TABLE on InnoDB and thinking it ‘optimises’ like OPTIMIZE TABLE.
On the example next to this theory: Repair Table: create two demo rows, then SELECT qty >= 2 ordered. Say which labels come back.
Exam tip
MyISAM: REPAIR TABLE. InnoDB: don’t; restore from backup.