Code Snippet

Just another Code Snippet site

[Oracle] Change TEMP tablespace file(s)

List current files :

SELECT file_name, tablespace_name, 
       bytes/1024/1024 MB, blocks
FROM dba_temp_files
ORDER BY tablespace_name, file_name;

Remove file :

ALTER DATABASE TEMPFILE '/opt/oracle/tablespaces/tmp/temp02.dbf' DROP INCLUDING DATAFILES;

Add new file :

ALTER TABLESPACE temp ADD TEMPFILE '/opt/oracle/tablespaces/tmp/temp01.dbf' SIZE 1G;


Comments are currently closed.