Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
JCL for copying the data from DB2 tables to the Dataset

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

New User


Joined: 18 Apr 2007
Posts: 13
Location: Bangalore

PostPosted: Thu May 24, 2007 2:12 pm    Post subject: JCL for copying the data from DB2 tables to the Dataset
Reply with quote

Hi,

Please provide me the JCL for copying the data from DB2 tables to the Dataset.







Thanks in Advance,
Back to top
View user's profile Send private message

Naresh Kumar Reddy P

New User


Joined: 24 May 2007
Posts: 8
Location: Bangalore

PostPosted: Thu May 24, 2007 2:53 pm    Post subject: Re: JCL
Reply with quote

Vinay,

You can use IKJEFT01 utility for copying the data from a DB2 table to mainframe dataset. You can give the DB2 query in SYSIN as the input, and the output dataset with the DD name SYSREC00.
Let us know for any issues.

Thanks
Reddy
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu May 24, 2007 4:01 pm    Post subject:
Reply with quote

Vinay,

You may use below JCL, with a little modification.
JCL is written with IKJEFT01, as stated earlier.

Code:
//JOBCARD
//*                                                         
/*ROUTE XEQ DB2P                                             
//*                                                         
//STEP000  EXEC UCC11RMS,PARM=F                             
//*                                                         
//STEP030 EXEC PGM=IKJEFT01,                                 
//             DYNAMNBR=20,                                 
//             REGION=4M                                     
//*                                                         
//STEPLIB  DD  DSN=DB2SYS1.VEND.LOADLIB,                     
//             DISP=SHR                                     
//*                                                         
//SYSREC00 DD  DSN=HLQ.OUT.FILE
//             DISP=(NEW,CATLG,DELETE),                       
//             UNIT=SYSDA                                   
//*                                                         
//SYSPUNCH DD SYSOUT=*                                         
//*                                                           
//SYSTSPRT DD  SYSOUT=*                                       
//SYSPRINT DD  SYSOUT=*                                       
//SYSUDUMP DD  SYSOUT=*                                       
//SYSTSIN  DD  *                                               
  DSN SYSTEM(DB2P)                                             
  RUN PROGRAM(DSNTIAUL) PLAN(DSNTIAUL) -                       
  PARM('SQL')                                                 
/*                                                             
//*                                                           
//SYSIN    DD  *                                               
   
YOUR QUERY STATEMENT
/*
//*
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 Copy 4 byte of data from the last rec... arunsoods DFSORT/ICETOOL 9 Fri Oct 06, 2017 12:15 pm
No new posts opening a dataset after reading it fr... arunsoods DFSORT/ICETOOL 5 Wed Oct 04, 2017 3:54 pm
This topic is locked: you cannot edit posts or make replies. PS file data should be passed as symb... d_sarlie JCL & VSAM 15 Tue Oct 03, 2017 5:18 am
No new posts File Aid tool to compare numeric data balaji81_k Compuware & Other Tools 2 Tue Sep 26, 2017 3:35 am
No new posts Question related to Data dictionary f... rexx77 SYNCSORT 3 Thu Aug 31, 2017 7:23 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us