At 16:40 -0600 3/25/02, Steve Buehler wrote:
>Is there anyway to drop a group of tables with a wildcard in MySql?
>I have tried:
>DROP TABLE IF EXISTS division1s*
>DROP TABLE IF EXISTS division1s(*)
>but neither one works. I am hoping that there is a good useable
>answer to this.
The syntax described in the manual shows what what you want to do is not
supported. You can't do it directly in SQL.
But depending on the context in which you're issuing the statement,
you can achieve the objective by other means. For example, if you're
using some kind of API, you can use SHOW TABLES LIKE 'division1s%',
then use the resulting list of tables to construct a DROP TABLES
statement that drops the tables.
>Thanks in advance