Rookie using DSNTEP2 and IBM JCL – Need Help with JCL

105 pts.
Tags:
DB2
DSNTEP2
EXEC
JCL
SQL
I'd appreciate some help here. My JCL background is HP3000 / MPEX and HP-UX, but my IBM mainframe JCL experience is over ten (10) years old. So I'm having problems creating a JCL - my brain can't remember command syntax's from that long ago. I need to create a JCL that will accept an input file of SQL statements, EXEC DSNTEP2, and output the results of the SQL to a file. Does anyone have a sample program that I could build off of? I can be reached off-line at my work address: jonathanDOTwalkerATcra-arcDOTgcDOTca (the obvous substitutions!) My profile e-mail is my home address. Thanks for any suggestions the community can provide. Jon

Answer Wiki

Thanks. We'll let you know when a new response is added.

//XXXXXX JOB (9999,9999,,99),’UTIL JOB’,
// CLASS=A,MSGCLASS=U,MSGLEVEL=(1,1),REGION=0M,
// NOTIFY=&SYSUID
//JOBLIB DD DISP=SHR,DSN=SYS2.xxxx.DB2.RUNLIB.LOAD
/*ROUTE PRINT Rxx
//*
//STEP10 EXEC PGM=IKJEFT01
//SYSTSPRT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSTSIN DD *
DSN SYSTEM(DB2)
RUN PROGRAM(DSNTEP2)
//SYSIN DD *
put statements here
//

You can use this. Anything marked with an X is isnstallation depenedent, basicallly a valid jobcard, remote printer if you need one and the library name if it is not link listed.

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Jonty Walker
    Is there a way to remove the SPUFI-like column headers and SQL source produced by DSNTEP2 from the output file?
    105 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following