In this Tutorial we will see how to rename the table name in Postgresql with example. Let’s see
- How to rename the table name in Postgresql with example.
Syntax:
ALTER TABLE table_name
RENAME TO new_table_name
RENAME TO new_table_name
The table that we use is
odetails:
Lets rename the above table as OrderDetails as shown below
ALTER TABLE odetails RENAME TO OrderDetails
So the new table name is “OrderDetails”