Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
Remove dupicates and format the output file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
Author Message
suma_infy

New User


Joined: 03 Oct 2008
Posts: 5
Location: chennai

PostPosted: Thu Oct 23, 2008 4:40 pm    Post subject: Remove dupicates and format the output file
Reply with quote

hello,
There is a requirement in which i need to remove duplicates and retain the duplicates in another file with certain format.
using the following JCL i removed the duplicates:

Code:
         
//STEP1    EXEC PGM=ICETOOL                                       
//TOOLMSG  DD SYSOUT=*                                           
//DFSMSG   DD SYSOUT=*                                         
//SYSOUT   DD SYSOUT=*                                           
//INDD1    DD DSN=TTOI.SUMA.FILE1,DISP=SHR                       
//OUTDD1   DD DSN=TTOI.SUMA.SORTXSUM.OUTPUT,                     
//            DISP=SHR                                           
//SORTXSUM DD DSN=TTOI.SUMA.SORTDUP2.OUTPUT,                     
//            DISP=SHR                                           
//TOOLIN   DD *                                                   
  SELECT FROM(INDD1) TO(OUTDD1) ON(1,1,CH) FIRST DISCARD(SORTXSUM)
/*


I need to format my output file, i tried including outrec option but it is not allowed in it...
OUTREC OPTION :
OUTREC FIELDS=(1:1,14,16:28,19,36:16,11,49:49,22)
Back to top
View user's profile Send private message
References
Moved: Thu Oct 23, 2008 4:42 pm by superk From JCL to DFSORT/ICETOOL
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 4684
Location: San Jose, CA

PostPosted: Thu Oct 23, 2008 9:30 pm    Post subject:
Reply with quote

You need to use an OUTFIL statement, not an OUTREC statement.

Which file are you trying to reformat - OUTDD1 or SORTXSUM or both?

If you want to reformat OUTDD1 and SORTXSUM, you would use this DFSORT/ICETOOL job:

Code:

//STEP1    EXEC PGM=ICETOOL
//TOOLMSG  DD SYSOUT=*
//DFSMSG   DD SYSOUT=*
//SYSOUT   DD SYSOUT=*
//INDD1    DD DSN=TTOI.SUMA.FILE1,DISP=SHR
//OUTDD1   DD DSN=TTOI.SUMA.SORTXSUM.OUTPUT,
//            DISP=SHR
//SORTXSUM DD DSN=TTOI.SUMA.SORTDUP2.OUTPUT,
//            DISP=SHR
//TOOLIN   DD *
  SELECT FROM(INDD1) TO(OUTDD1) ON(1,1,CH) FIRST DISCARD(SORTXSUM)-
   USING(CTL1)
/*
//CTL1CNTL DD *
  OUTFIL FNAMES=OUTDD1,BUILD=(1:1,14,16:28,19,36:16,11,49:49,22)
  OUTFIL FNAMES=SORTXSUM,BUILD=(1:1,14,16:28,19,36:16,11,49:49,22)
/*


If you want to do something else, let me know what you want to do.
Back to top
View user's profile Send private message
suma_infy

New User


Joined: 03 Oct 2008
Posts: 5
Location: chennai

PostPosted: Fri Oct 24, 2008 9:48 am    Post subject:
Reply with quote

Thanks a lot for ur valuable suggestion. Its working fine now icon_smile.gif

Thanks & Regards,
suma
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1