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, 3159🔥, 0💬
Popular Posts:
How To Insert New Line Characters into Strings in SQL Server Transact-SQL? If you want to break a st...
How to continue to the next iteration of a WHILE loop in SQL Server Transact-SQL? How to use CONTINU...
How to print value on console in SQL Server Transact-SQL? How to use the PRINT statements? In Transa...
How To Replace Given Values with NULL using NULLIF() in SQL Server Transact-SQL? Sometime you want t...
How to download Microsoft SQL Server 2005 Express Edition in SQL Server? Microsoft SQL Server 2005 E...