Rename tablespace in oracle DB

Rename tablespace name in Oracle database

  1. Create a TEST tablespace for rename example
SQL> create tablespace TEST datafile 'C:\test.dbf' size 1G autoextend on next 500M;

Tablespace created.

2. Rename the TEST tablespace to PROD.

SQL> alter tablespace TEST rename to PROD;

Tablespace altered.

3. Check the renamed tablespace.

SQL> select file_name from dba_data_files where tablespace_name = 'PROD';

FILE_NAME
--------------------------------------------------------------------------------
C:\TEST.DBF

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.