Collections:
Rename an Existing Table in MySQL
How To Rename an Existing Table in MySQL?
✍: FYIcenter.com
If you want to rename an existing table, you can use the "ALTER TABLE ... RENAME TO" statement. The tutorial script below shows you a good example:
mysql> ALTER TABLE tip RENAME TO faq; Query OK, 0 rows affected (0.01 sec) mysql> SELECT * FROM faq; +----+-------------+-------------------------+--------+ | id | title | description | author | +----+-------------+-------------------------+--------+ | 1 | Learn MySQL | Visit dev.fyicenter.com | NULL | +----+-------------+-------------------------+--------+ 1 row in set (0.00 sec)
⇒ Drop an Existing Table in MySQL
⇐ Rename an Existing Column in a Table in MySQL
2018-02-14, 2159🔥, 0💬
Popular Posts:
What are binary literals supported in SQL Server Transact-SQL? Binary literals in Transact-SQL are s...
How To Get the Definition of a User Defined Function Back in SQL Server Transact-SQL? If you want ge...
What Privilege Is Needed for a User to Delete Rows from Tables in Another Schema in Oracle? For a us...
What is dba.FYIcenter.com Website about? dba.FYIcenter.com is a Website for DBAs (database administr...
What Are the Underflow and Overflow Behaviors on FLOAT Literals in SQL Server Transact-SQL? If you e...