0

Would this find and drop all tables with the given prefix?

DROP TABLE IF EXISTS 'bak_'

There are other tables with "mmp_hdkji" that I do not want to drop.

modernmagic
  • 141
  • 10
  • 1
    possible duplicate of [Drop all tables whose names begin with a certain string](http://stackoverflow.com/questions/4393/drop-all-tables-whose-names-begin-with-a-certain-string) – The Blue Dog Mar 06 '14 at 09:13

1 Answers1

0

Since you're using phpMyAdmin, if PeteR's answer isn't to your liking, you can shift-click to select many tables at once.

From the database structure page, you can click the checkbox in front of each table you want. If, as in your case, there are a number that are ordered one after the other, click the top one then shift-click the bottom one. The ones in between will also be selected. Once you have all your tables selected, click the "With selected:" dropdown and go to "Drop".

Isaac Bennetch
  • 11,830
  • 2
  • 32
  • 43