If you're using PHP, there should be a function for it.

You can also use IF NOT EXISTS in your table commands like:
CREATE TABLE IF NOT EXISTS, so that you don't overwrite anything.

What also might come in handy here is either SHOW TABLES (provided you're in
the right database), or DESCRIBE tablename

- Jonathan

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 14, 2001 8:34 AM
To: [EMAIL PROTECTED]
Subject: Table Exists


What is the easiest way to check if a table exists in the current
database?  I checked the documentation, and couldn't find anything (but
maybe I missed it).

Glen

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to