MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Unload IMS Database

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL)
View previous topic :: View next topic  
Author Message
programmer1
Beginner


Joined: 18 Feb 2004
Posts: 138
Topics: 14

PostPosted: Wed Feb 18, 2004 2:44 am    Post subject: Unload IMS Database Reply with quote

Hi,

Can anyone help me with a JCL to unload an IMS segment to a flat file.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12368
Topics: 75
Location: San Jose

PostPosted: Wed Feb 18, 2004 7:00 am    Post subject: Reply with quote

programmer1,


Do you have file-aid for IMS? or any of the BMC utilities ?

Kolusu
_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
manojagrawal
Beginner


Joined: 25 Feb 2003
Posts: 124
Topics: 29

PostPosted: Wed Feb 18, 2004 3:52 pm    Post subject: Reply with quote

Are you looking for something like this:

Code:
//STEP10  EXEC PGM=HPSCMAIN,REGION=0M,                               
//             PARM='FUNC=UL,DBD=XXXXXXX,DBRC=N,IRLM=N'             
//IMS      DD DSN=XXX.PROD.DBDLIB,DISP=SHR                       
//DFSRESLB DD DSN=IMS.PROD.RESLIB,DISP=SHR                         
//DFSVSAMP DD DSN=XXXX.PP.CNTL01(BUFSIZE),DISP=SHR               
//SYSUDUMP DD SYSOUT=*                                               
//HPSOUT   DD SYSOUT=*                                               
//HPSTRACE DD SYSOUT=*                                               
//HPSSNAP  DD SYSOUT=*                                               
//XXXXXX1  DD DSN=&XX.YYY.XXXXXX1,DISP=SHR                         
//XXXXXX2  DD DSN=&XX.YYY.XXXXXX2,DISP=SHR                         
//XXXXXX3  DD DSN=&XX.YYY.XXXXXX3,DISP=SHR                         
//XXXXXX4  DD DSN=&XX.YYY.XXXXXX4,DISP=SHR                         
//SYSUT2   DD DSN=&XX.IMS.UNLOAD(+1),DISP=(,CATLG,DELETE),   
//            RECFM=VB,LRECL=32756,BUFNO=10,                         
//            SPACE=(TRK,(450,150),RLSE)



I got this from what my project uses. Kolusu, can you explain whether this is what you meant by BMC utilities? I Would like to know the options available to do this.
_________________
Thanks & Regards,
Manoj.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12368
Topics: 75
Location: San Jose

PostPosted: Wed Feb 18, 2004 4:33 pm    Post subject: Reply with quote

Manoj,

BMC has an utility called MAXM Reorg which can be used to unload IMS databases.I am not aware of the pgm PGM=HPSCMAIN in your JCL. BMC utility runs with same pgm DFSRRC00 as all BMP's use. Who is the vendor for that pgm?

Read chapter 4 in this [url=http://documents.bmc.com/supportu/documents/76/12/7612/7612.pdf]MAXM
_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Sreejith
Intermediate


Joined: 02 Dec 2002
Posts: 155
Topics: 25
Location: N.Ireland

PostPosted: Thu Feb 19, 2004 4:12 am    Post subject: Reply with quote

If you have fileaid you can either use the extract utility or the PRINT utility. Following is a JCL using the PRINT option. Change IMSID and DBDname
You can use SQL like statement to extract segments.

Code:
//*----------------------------------------------------------------* 
//* FILE-AID FOR IMS BATCH - BMP REGION - USING DYNAMIC PSB        * 
//*----------------------------------------------------------------* 
//*                                                                   
//BATBMPDY PROC  RGN='5096K',                                         
//*        DEV=SYSDA,                                                 
//         DEBUG='',                                                 
//         PSBTYPE=D,          PSB IS DYNAMIC                         
//         IMSID=RSGT,         FA/IMS ID ASSIGNED IN BMP IPARMS       
//         DBDNAME=F5131DBD,   DBD NAME                               
//         IN=,OUT=,OPT=,SPIE=,TEST=,DIRCA=,PRLD=,STIMER=,           
//         CKPTID=,PARDLI=,CPUTIME=,NBA=,OBA=,IMSID=,AGN=,           
//         SSM=,PREINIT=,ALTID=,APARM=                               
//********************************************************************
//BATDV10  EXEC PGM=IXPBATDV,REGION=&RGN,                             
//         PARM=('&DEBUG/NBMP',                                       
//         '&PSBTYPE&IMSID',                                         
//         '&DBDNAME,&IN,&OUT',                                       
//         '&OPT&SPIE&TEST&DIRCA,&PRLD,&STIMER',                     
//         '&CKPTID,&PARDLI,&CPUTIME,&NBA,&OBA',                     
//         '&IMSID,&AGN,&SSM,&PREINIT,&ALTID,&APARM')                 
//*                                                                   
//STEPLIB  DD DSN=IMSVS.RSGT.RESLIB,                                 
//            DISP=SHR                                               
//         DD DSN=IMS2.DFSMDA0X,                                     
//            DISP=SHR                                               
//         DD DSN=IMSVS.FILEAID.LOAD,                                 
//            DISP=SHR                                               
//DFSRESLB DD DSN=IMSVS.RSGT.RESLIB,DISP=SHR                         
//IMS      DD DSN=IMSVS.FILEAID.PSBLOAD,DISP=SHR                     
//         DD DSN=IMSVS.DBDLIB.RSG,DISP=SHR                           
//IMSACB   DD DSN=IMSVS.TSTACBA.RSG,DISP=SHR                         
//         DD DSN=IMSVS.TSTACBB.RSG,DISP=SHR                         
//         DD DSN=IMSVS.TEST.ACBDYNAM,DISP=SHR                         
//SYSUDUMP DD SYSOUT=(*)                                               
//SYSPRINT DD SYSOUT=(*)                                               
//SYSOUT   DD SYSOUT=(*)                                               
//IXPMLIB  DD DSN=IMSVS.FILEAID.ISPMLIB,DISP=SHR                       
//*IXPIN   DD dsn=xxxxx,disp=old                                       
//IXPOUT   DD DSN=DE62975.COBOL.SOURCE.OUTPUT,DISP=SHR                 
//*           DISP=(NEW,CATLG,DELETE),                                 
//*           SPACE=(TRK,(1,1)),                                       
//*           DCB=(RECFM=FB,LRECL=133,BLKSIZE=1330),                   
//*           UNIT=&DEV                                               
//IXPAT    DD DUMMY                                                   
//IXPSTATS DD DUMMY                                                   
//IXPFD    DD DSN=RSG6.IMSPP.XREF,DISP=SHR                             
//IXPC1    DD DSN=LIB1.COPYLIB.PRODRSG,DISP=SHR                       
//*-----------------------------------------------------------------   
//*IXPED   DD DSN=DE62975.COBOL.SOURCE(COUNT1),DISP=SHR               
//IXPED    DD DUMMY                                                   
//*-----------------------------------------------------------------   
//*                                                                   
//        PEND                                                         
//*                                                                   
//BMPBATDY EXEC BATBMPDY                                               
//BATDV10.IXPED DD *                                                   
TITLE LINE01='extract record(s) from F513';       
SET PRINT=FPRINT;                                 
SELECT SEGMENT=your-segment                             
       WHERE your field = '129711'               
       MAX=ALL                                     
PRINT SEGMENT=your-segment;
//*                                                                   
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
programmer1
Beginner


Joined: 18 Feb 2004
Posts: 138
Topics: 14

PostPosted: Wed Mar 17, 2004 1:32 am    Post subject: Reply with quote

Thanx alot people.

I appretiate your help.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Job Control Language(JCL) All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group