During the development lifecycle, we may decide on a name for a and later want to it based on the usage of the table.

Let7;s assume that there is a TABLE with name TransportType and the new name has been identified as TransportTypes (observe the extra “s̶; in the name), it is tedious to create a new table, copy all the records and the old table.

has a one step to rename tables.

RENAME TABLE oldTableName TO newTableName

Following our example, it would look like:

RENAME TABLE TransportType to TransportTypes

Source link
thanks you RSS link
( http://www.devx.com//database-development/mysql/mysql-rename-table-180429075524.html)


Please enter your comment!
Please enter your name here