View previous topic :: View next topic
|
Author |
Message |
subdalal
New User
Joined: 27 Sep 2010 Posts: 21 Location: Boudh
|
|
|
|
RUN PROGRAM(DSNTEP2) PLAN(DSNTEP2) ---> The o/p gets printed in SYSPRINT.
RUN PROGRAM(DSNTIAUL) PLAN(DSNTIAUL) PARMS('SQL') ---> The o/p can be moved to a PS file. need to give the PS file name in DD name SYSREC00
For moving the output to a PS File:
//JOBCARD
//PS000 EXEC PGM=IKJEFT01
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSDBOUT DD SYSOUT=*
//SYSREC00 DD DSN=<PSFile_Name>,
// DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSPUNCH DD SYSOUT=*
//SYSTSIN DD *
DSN SYSTEM(<System_Name>)
RUN PROGRAM(DSNTIAUL) PLAN(DSNTIAUL) PARMS('SQL')
/*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
<SQL Query>
/*
To have the output in Sysprint:
//JOBCARD
//PS000 EXEC PGM=IKJEFT01
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSDBOUT DD SYSOUT=*
//SYSTSPRT DD SYSOUT=*
//SYSPUNCH DD SYSOUT=*
//SYSTSIN DD *
DSN SYSTEM(<System_Name>)
RUN PROGRAM(DSNTEP2) PLAN(DSNTEP2)
LIB (<Library_Name>)
END
/*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
<SQL Query>
/* |
|
Back to top |
|
|
Pandora-Box
Global Moderator
Joined: 07 Sep 2006 Posts: 1592 Location: Andromeda Galaxy
|
|
|
|
Are you giving a sample or stating a problem? |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
they look like hints ...
but ...
- use the code tags to make the code snippets more readable
- and ...
since You want to look like an expert refrain from using invalid terminology
You do not run a query thru jcl ...
jcl is just the weird language used to in tell the system to run some program
so You might be better off talking about ...
DB2/SQL utilities that can be used to execute a query without having to write a program
and show the JCL used to invoke that utility |
|
Back to top |
|
|
Rohit Umarjikar
Global Moderator
Joined: 21 Sep 2010 Posts: 3048 Location: NYC,USA
|
|
|
|
But , What is the issue here or is it just a fyi? |
|
Back to top |
|
|
|