Alex,

Create a sql script with your query ( eg. sql_script.sql)

Then create a batch script like the one below (script.bat)

sqlplus -s user/password @sql_script.sql > logfile

You will need to run the script.bat which will login and execute your Oracle
Script and log results to a logfile.

Regards
Suhen


Hi gurus!!!
I need execute any scripts in win nt like oracle in unix!!!
example:
sqlplus user/password << fin
SELECT s.sid,
       s.serial#,
       p.pid,
       p.spid,
       s.osuser,
       s.machine,
       s.program
FROM v\$session s, v\$process p
WHERE p.addr = s.paddr
  AND s.schemaname <> 'SYS'
  ORDER BY p.spid,s.sid, p.pid, p.spid;
fin

@lex
------------------------------------------------------------
  Lic. Alexander Ord��ez Arroyo 
  Caja Costarricense del Seguro Social                             
  Soporte T�cnico - Divisi�n de Inform�tica                     
  Telefono: 295-2004, San Jos�, Costa Rica                    
  [EMAIL PROTECTED]        Icq# 30173325

------------------------------------------------------------
The true is out there in WWW

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Alexander Ordonez
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Suhen Pather
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to