CREATE OR REPLACE directory <directory name> AS '<O/S directory>';
SQL> SELECT * FROM dba_directories WHERE directory_name = 'DUMP_DIR';
OWNER DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS DUMP_DIR
/u04/oradata1
SQL> CREATE OR REPLACE directory DUMP_DIR AS '/u01/oradata';
Directory created.
SQL> SELECT * FROM dba_directories WHERE directory_name = 'DUMP_DIR';
OWNER DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS DUMP_DIR
/u01/oradata
SQL>
## This has changed the directory path from /u04 to /u01.
SQL> SELECT * FROM dba_directories WHERE directory_name = 'DUMP_DIR';
OWNER DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS DUMP_DIR
/u04/oradata1
SQL> CREATE OR REPLACE directory DUMP_DIR AS '/u01/oradata';
Directory created.
SQL> SELECT * FROM dba_directories WHERE directory_name = 'DUMP_DIR';
OWNER DIRECTORY_NAME
------------------------------ ------------------------------
DIRECTORY_PATH
--------------------------------------------------------------------------------
SYS DUMP_DIR
/u01/oradata
SQL>
## This has changed the directory path from /u04 to /u01.
No comments:
Post a Comment