Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Need Help on BATCH SQL JCL.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
ramsfm

New User


Joined: 05 May 2006
Posts: 12
Location: Pune

PostPosted: Thu Nov 09, 2006 10:50 am    Post subject: Need Help on BATCH SQL JCL.
Reply with quote

Hi,

Can any one give model JCL for batch sql execution.

I created JCL i gaven db2 subsystem at SYSTIN DD * and SQL in SYSIN DD * ...........is it mandatory to give remaining run program and lib parms. if yes please let me know what is that LIB? how can i find that library name in my system.
Back to top
View user's profile Send private message

shreevamsi

Active User


Joined: 23 Feb 2006
Posts: 305
Location: Hyderabad,India

PostPosted: Thu Nov 09, 2006 11:39 am    Post subject:
Reply with quote

Hi this is what ur looking for ??

Code:
//STEP0001   EXEC PGM=IKJEFT01,REGION=4096K,DYNAMNBR=100
//STEPLIB   DD DSN=SYS1.DB2X.SDSNLOAD,DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSPUNCH DD DUMMY
//SYSREC00 DD DSN=KBY@V1.OUTPUT.RESULT, <<SPECIFY OUTPUT DS
//            DISP=(NEW,CATLG,DELETE),
//            SPACE=(CYL,(100,100),RLSE)
//*
//SYSTSIN  DD *
     DSN SYSTEM(DB2)
     RUN PROGRAM(DSNTIAUL) LIB('SYSDB2.RUNLIB.LOAD') -
        PARMS('SQL') PLAN(DSNTIAUL)
     END
/*
//SYSIN    DD *
     SELECT COUNT( DISTINCT(A) )FROM
     QUALIFIER. TABLE NAME A
/*
Back to top
View user's profile Send private message
ramsfm

New User


Joined: 05 May 2006
Posts: 12
Location: Pune

PostPosted: Thu Nov 09, 2006 1:55 pm    Post subject:
Reply with quote

Thanks for your reply.

//SYSTSIN DD *
DSN SYSTEM(DB2)
RUN PROGRAM(DSNTIAUL) LIB('SYSDB2.RUNLIB.LOAD') -
PARMS('SQL') PLAN(DSNTIAUL)
END

The above systax
RUN PROGRAM(DSNTIAUL) LIB('SYSDB2.RUNLIB.LOAD') -
PARMS('SQL') PLAN(DSNTIAUL)
END

These parms are mandataory if yes will it change for system to system or common for all. especially LIB parm?
Back to top
View user's profile Send private message
ramsfm

New User


Joined: 05 May 2006
Posts: 12
Location: Pune

PostPosted: Thu Nov 09, 2006 2:29 pm    Post subject:
Reply with quote

when gave those parameters the following run time error message i am getting....

------------------------------------
READY
DSN SYSTEM(XTD1) RUN PROGRAM(DSNTIAUL) LIB('SYSDB2.RUNLIB.LOAD') PARMS('SQL'
IKJ56712I INVALID KEYWORD, RUN
IKJ56712I INVALID KEYWORD, PROGRAM(DSNTIAUL)
IKJ56712I INVALID KEYWORD, LIB('SYSDB2.RUNLIB.LOAD')
IKJ56712I INVALID KEYWORD, PARMS('SQL')
IKJ56712I INVALID KEYWORD, PLAN(DSNTIAUL)
READY
END
READY
END
-------------------------------
Can you explain me about that LIB? what it exactly ?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts HLIST Utility In Batch Virendra Shambharkar TSO/ISPF 4 Fri Apr 07, 2017 3:38 pm
No new posts Batch job tuning sgandhla Testing & Performance analysis 5 Fri Mar 24, 2017 9:41 pm
No new posts MIPS/CPU consumption reduction in Batch vishwakotin DFSORT/ICETOOL 4 Sat Mar 18, 2017 5:46 pm
No new posts How does a called pgm know if its cal... Graeme Westerman COBOL Programming 5 Tue Nov 29, 2016 9:25 pm
This topic is locked: you cannot edit posts or make replies. MIPS reduction for Batch job Virendra Shambharkar All Other Mainframe Topics 8 Mon Nov 07, 2016 4:02 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us