RENAME
The DDL command RENAME
, as expected is used to change names in our database.
1. RENAME TABLE
Perhaps we should choose a more appropriate name for our table in our music store. We can do so with the following.
TEXT/X-SQL
1ALTER TABLE albums
2RENAME TO our_albums;
2. RENAME COLUMN
Or maybe we want to rename a column, we can do the following.
TEXT/X-SQL
1ALTER TABLE albums
2RENAME COLUMN title TO album_name;