3353
MySQLERRORNotableDDL / IndexesHIGH confidence
Column cannot be dropped because it is used by a functional index
Production Risk
Low — DDL fails; no column or index is removed.
How to reproduce
trigger — this will error
trigger — this will error
ALTER TABLE t DROP COLUMN col; -- col is used in a functional index
expected output
ERROR 3353 (HY000): Column 'col' is used by a functional index and cannot be dropped.
Fix
Drop index then column
Drop index then column
ALTER TABLE t DROP INDEX idx, DROP COLUMN col;
Why this works
Removing the functional index first allows the column to be dropped safely.
What not to do
✕
Sources
Official documentation ↗
MySQL 8.0 — 3353 ER_DEPENDENT_BY_FUNCTIONAL_INDEX
Content generated with AI assistance and reviewed for accuracy. Found an error? hello@errcodes.dev