Execute Oracle Script in cmd or bath mode

Question: Hi,

Please, help me to solve this problem, In Oracle 9.2.

I need to turn off the archive mode, but I need do it in command mode in a .bat or .cmd command.

Can somebody help me with this?

A lot of thank`s


ExecScript

Answer:
Hi,

I haven't tried it, but you may look into something
similar to the following; I am not a fan of turning
archiving off and on too often. Perhaps you can do whatever
you need to do in 'noarchive' mode, (i.e rebuilding indexes,
etc..)

Ensure that log_archive_start = true in init<sid>.ora

startup mount exclusive
connect interal; (Or possibly, connect sys/<pwd> as sysdba')
alter database noarchivelog;
alter database open;

startup mount exclusive
connect internal
alter database archivelog;
alter database open;

Test well !

Answer:
That is correct.

Now since I make to be able it to run from a file .cmd or .bat?

Thank´s

ExecScript

Answer:
sqlplus /NOLOG @sql_script.sql
Copyright ?2007 - 2008 www.jt77.com