SQL> shutdown abort .com

About DBA Queries DBA Scripts Quick Guides Nooleus Other Stuff Contact
Andy only 
 

cr_hot_backup.sql

set lines 999 pages 999
set verify off
set feedback off
set heading off

spool begin_backup.sql

select 'alter tablespace ' || tablespace_name || ' begin backup;' tsbb
from    dba_tablespaces
where   contents != 'TEMPORARY'
order by tablespace_name
/
spool off

spool end_backup.sql

select 'alter tablespace ' || tablespace_name || ' end backup;' tseb
from    dba_tablespaces
where   contents != 'TEMPORARY'
order by tablespace_name
/
spool off

Copyright© 2007-2010 Andrew Barry