Drop all partitions from a table MySQL

5.1k Views Asked by At

How can I drop all partitions from a table in MySQL. I know you can drop specific partitions with ALTER TABLE table_name DROP PARTITION p0, p1, but is there a way to not list every single partition name?

1

There are 1 best solutions below

0
danblack On BEST ANSWER

ALTER TABLE table_name REMOVE PARTITIONING can achieve what you want.

test fiddle