dbTalk Databases Forums  

SPOOL INTO A JOB

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss SPOOL INTO A JOB in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #11  
Old   
CenturionX
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:29 PM






Hello Malcom,

You are the man.

That's exactly what was failing.

I specified the current directory and now my .bat file is working
fine.

Thanks a lot.

Reply With Quote
  #12  
Old   
CenturionX
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:29 PM






Hello Malcom,

You are the man.

That's exactly what was failing.

I specified the current directory and now my .bat file is working
fine.

Thanks a lot.

Reply With Quote
  #13  
Old   
CenturionX
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:29 PM



Hello Malcom,

You are the man.

That's exactly what was failing.

I specified the current directory and now my .bat file is working
fine.

Thanks a lot.

Reply With Quote
  #14  
Old   
Malcolm Dew-Jones
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:51 PM



CenturionX (darwinbaldrich (AT) gmail (DOT) com) wrote:
: Hello Sybrand,

: Thanks for respond.
: I'll change the question.

: I'm working with Oracle 10.2.0.4.0 on Windows.

: I created a job to execute a .bat file

: JOB:
: ---------
: begin
: dbms_scheduler.create_job (
: job_name =>'DEL_ALERT_LOG',
: job_type =>'executable',
: job_action =>'c:\windows\system32\cmd.exe /c H:\Reports\Programs
: \wip_inventory_dbp.bat > nul',
: enabled => true,
: auto_drop => true
: );
: commit;
: end;
: /

: .BAT file
: -------------
: :ELETE OLD LOG FILE
: DEL wip_inventory_dbp.log

: ::GENERATE REPORT
: ECHO. >> wip_inventory_dbp.log
: ECHO Generating report... >> wip_inventory_dbp.log
: ECHO. >> wip_inventory_dbp.log
: sqlplus cms/cms@LEGACY_JACKSONVILLE_DEV @H:\Reports\Programs
: \wip_inventory.sql

: The only thing that executes right is the sqlplus command, The rest:
: del, echo, doesn't work (just DOS commands does nothing).
: How can i fix it.
: I need a log file to follow the process and i need to add more dos
: commands in the script.

: Thanks for your help.

I would guess that the bat file needs to set a useable current directory
before trying to run the commands. If the Reports dir was a good location
(which I doubt, but what the heck) then something like

:ELETE OLD LOG FILE
H:
chdir H:\Reports\Programs
DEL wip_inventory_dbp.log
...etc...

Reply With Quote
  #15  
Old   
Malcolm Dew-Jones
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:51 PM



CenturionX (darwinbaldrich (AT) gmail (DOT) com) wrote:
: Hello Sybrand,

: Thanks for respond.
: I'll change the question.

: I'm working with Oracle 10.2.0.4.0 on Windows.

: I created a job to execute a .bat file

: JOB:
: ---------
: begin
: dbms_scheduler.create_job (
: job_name =>'DEL_ALERT_LOG',
: job_type =>'executable',
: job_action =>'c:\windows\system32\cmd.exe /c H:\Reports\Programs
: \wip_inventory_dbp.bat > nul',
: enabled => true,
: auto_drop => true
: );
: commit;
: end;
: /

: .BAT file
: -------------
: :ELETE OLD LOG FILE
: DEL wip_inventory_dbp.log

: ::GENERATE REPORT
: ECHO. >> wip_inventory_dbp.log
: ECHO Generating report... >> wip_inventory_dbp.log
: ECHO. >> wip_inventory_dbp.log
: sqlplus cms/cms@LEGACY_JACKSONVILLE_DEV @H:\Reports\Programs
: \wip_inventory.sql

: The only thing that executes right is the sqlplus command, The rest:
: del, echo, doesn't work (just DOS commands does nothing).
: How can i fix it.
: I need a log file to follow the process and i need to add more dos
: commands in the script.

: Thanks for your help.

I would guess that the bat file needs to set a useable current directory
before trying to run the commands. If the Reports dir was a good location
(which I doubt, but what the heck) then something like

:ELETE OLD LOG FILE
H:
chdir H:\Reports\Programs
DEL wip_inventory_dbp.log
...etc...

Reply With Quote
  #16  
Old   
Malcolm Dew-Jones
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:51 PM



CenturionX (darwinbaldrich (AT) gmail (DOT) com) wrote:
: Hello Sybrand,

: Thanks for respond.
: I'll change the question.

: I'm working with Oracle 10.2.0.4.0 on Windows.

: I created a job to execute a .bat file

: JOB:
: ---------
: begin
: dbms_scheduler.create_job (
: job_name =>'DEL_ALERT_LOG',
: job_type =>'executable',
: job_action =>'c:\windows\system32\cmd.exe /c H:\Reports\Programs
: \wip_inventory_dbp.bat > nul',
: enabled => true,
: auto_drop => true
: );
: commit;
: end;
: /

: .BAT file
: -------------
: :ELETE OLD LOG FILE
: DEL wip_inventory_dbp.log

: ::GENERATE REPORT
: ECHO. >> wip_inventory_dbp.log
: ECHO Generating report... >> wip_inventory_dbp.log
: ECHO. >> wip_inventory_dbp.log
: sqlplus cms/cms@LEGACY_JACKSONVILLE_DEV @H:\Reports\Programs
: \wip_inventory.sql

: The only thing that executes right is the sqlplus command, The rest:
: del, echo, doesn't work (just DOS commands does nothing).
: How can i fix it.
: I need a log file to follow the process and i need to add more dos
: commands in the script.

: Thanks for your help.

I would guess that the bat file needs to set a useable current directory
before trying to run the commands. If the Reports dir was a good location
(which I doubt, but what the heck) then something like

:ELETE OLD LOG FILE
H:
chdir H:\Reports\Programs
DEL wip_inventory_dbp.log
...etc...

Reply With Quote
  #17  
Old   
Malcolm Dew-Jones
 
Posts: n/a

Default Re: SPOOL INTO A JOB - 09-11-2008 , 05:51 PM



CenturionX (darwinbaldrich (AT) gmail (DOT) com) wrote:
: Hello Sybrand,

: Thanks for respond.
: I'll change the question.

: I'm working with Oracle 10.2.0.4.0 on Windows.

: I created a job to execute a .bat file

: JOB:
: ---------
: begin
: dbms_scheduler.create_job (
: job_name =>'DEL_ALERT_LOG',
: job_type =>'executable',
: job_action =>'c:\windows\system32\cmd.exe /c H:\Reports\Programs
: \wip_inventory_dbp.bat > nul',
: enabled => true,
: auto_drop => true
: );
: commit;
: end;
: /

: .BAT file
: -------------
: :ELETE OLD LOG FILE
: DEL wip_inventory_dbp.log

: ::GENERATE REPORT
: ECHO. >> wip_inventory_dbp.log
: ECHO Generating report... >> wip_inventory_dbp.log
: ECHO. >> wip_inventory_dbp.log
: sqlplus cms/cms@LEGACY_JACKSONVILLE_DEV @H:\Reports\Programs
: \wip_inventory.sql

: The only thing that executes right is the sqlplus command, The rest:
: del, echo, doesn't work (just DOS commands does nothing).
: How can i fix it.
: I need a log file to follow the process and i need to add more dos
: commands in the script.

: Thanks for your help.

I would guess that the bat file needs to set a useable current directory
before trying to run the commands. If the Reports dir was a good location
(which I doubt, but what the heck) then something like

:ELETE OLD LOG FILE
H:
chdir H:\Reports\Programs
DEL wip_inventory_dbp.log
...etc...

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.