您现在的位置是:首页 > 博文答疑 > DB2笔记系列 19 - JCL跑SQL博文答疑

DB2笔记系列 19 - JCL跑SQL

Leo2016-08-22【4】

简介JCL跑SQL例子

//RUNSQL01 JOB APPC#,LIBIN,                               

//             NOTIFY=&SYSUID,                            

//             MSGCLASS=B,                                

//             MSGLEVEL=(1,1),                            

//             CLASS=A                                    

//STEP01  EXEC PGM=IKJEFT01                               

//STEPLIB  DD  DSN=DSN710.SDSNLOAD,DISP=SHR               

//         DD  DSN=DSN710.SDSNEXIT,DISP=SHR               

//         DD  DSN=DSN710.RUNLIB.LOAD,DISP=SHR            

//SYSPRINT DD SYSOUT=*                                    

//SYSTSPRT DD SYSOUT=*                                    

//SYSTSIN   DD *                                          

 DSN SYSTEM(DB7G)                                         

 RUN PROGRAM(DSNTEP2) PLAN(DSNTEP71) PARMS('/SQLTERM(/)') -

     LIB('DSN710.RUNLIB.LOAD')                            

//SYSUDUMP DD SYSOUT=*                                    

//SYSIN     DD *                                          

 SELECT * FROM SYSIBM.SYSCOLUMNS WHERE TBNAME='TEST01'    

/*