Tim Johnson <[EMAIL PROTECTED]> wrote:
>    I would like to rename a table if it exists.
> 
> The following query
> IF EXISTS ALTER TABLE gwcc_members RENAME gwcc_members_bak;
> fails.
> 
> also 
> 
> ALTER TABLE IF EXISTS gwcc_members RENAME gwcc_members_bak;
> fails.
> 
> 
> 1)What is the correct syntax?

You should check if table exists, and then rename table.

> 2)Where is documentation.
> I'm using ver. 3.23.41

Documentation is included in all MySQL distributions. You can also find online 
documentation at:
        http://www.mysql.com/documentation/index.html



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
       <___/   www.mysql.com




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to