some help in synctool



Support for NetApp SyncSort for z/OS, Visual SyncSort, SYNCINIT, SYNCLIST and SYNCTOOL

some help in synctool

Postby fazillatheef » Wed Feb 27, 2008 11:57 am

Hi
I would like to have some help to do the particular problem using synctool.

I have two input PS
TRGE09.FIRST and TRGE09.SECOND (the record length is 10)
each PS contains a record and it contains a numerical value

and two output PS
TGRE09.OUT1 and TRGE09.OUT2 (the record length is 10)

I need to compare the fields from TRGE09.FIRST and TRGE09.SECOND
and if the first one is lesser than or equal to the second one
the first one is put into TGRE09.OUT1
or if the first one is greater than the second one
the second one is put into TRGE09.OUT2
fazillatheef
 
Posts: 18
Joined: Mon Feb 25, 2008 12:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: some help in synctool

 

Re: some help in synctool

Postby CICS Guy » Wed Feb 27, 2008 9:10 pm

Huh?

Maybe some samples of the input and expected output might be helpful......
CICS Guy
 
Posts: 255
Joined: Wed Jun 20, 2007 4:08 am
Has thanked: 0 time
Been thanked: 0 time

Re: some help in synctool

Postby Alissa Margulies » Thu Feb 28, 2008 2:18 am

Let me see if I understand your requirements. Basically, you want to keep only the smaller values. If the smaller value comes from the 1st file, put it in OUTFIL1, doing nothing with the record from File2. However, if the smaller value is in File2, then write the record from File2 to OUTPUT2 and do nothing with the record from File1. Am I correct so far?

And is there a key field in each file that will correspond the records from File1 to File2?
Alissa Margulies
Syncsort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
Alissa Margulies
Global moderator
 
Posts: 369
Joined: Tue Feb 26, 2008 11:15 pm
Location: USA
Has thanked: 1 time
Been thanked: 1 time

Re: some help in synctool

Postby fazillatheef » Thu Feb 28, 2008 8:27 am

yes ,what you have said is correct. But there is no key field for each record
fazillatheef
 
Posts: 18
Joined: Mon Feb 25, 2008 12:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: some help in synctool

Postby arunprasad.k » Thu Feb 28, 2008 3:48 pm

I have two input PS TRGE09.FIRST and TRGE09.SECOND (the record length is 10) each PS contains a record and it contains a numerical value


Does it mean each PS files has only one record?

Arun.
arunprasad.k
 
Posts: 110
Joined: Thu Dec 27, 2007 5:18 pm
Has thanked: 0 time
Been thanked: 0 time

Re: some help in synctool

Postby fazillatheef » Thu Feb 28, 2008 4:39 pm

yes
fazillatheef
 
Posts: 18
Joined: Mon Feb 25, 2008 12:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: some help in synctool

Postby William Thompson » Thu Feb 28, 2008 9:26 pm

As was said earlier:
CICS Guy wrote:Maybe some samples of the input and expected output might be helpful......
William Thompson
 
Posts: 86
Joined: Sat Jun 09, 2007 4:24 am
Location: Tucson AZ
Has thanked: 0 time
Been thanked: 1 time

Re: some help in synctool

Postby Alissa Margulies » Fri Feb 29, 2008 2:00 am

fazillatheef wrote:I would like to have some help to do the particular problem using synctool.
Any reason for wanting to specifically use SYNCTOOL for this application instead of SyncSort?
Alissa Margulies
Syncsort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
Alissa Margulies
Global moderator
 
Posts: 369
Joined: Tue Feb 26, 2008 11:15 pm
Location: USA
Has thanked: 1 time
Been thanked: 1 time

Re: some help in synctool

Postby Alissa Margulies » Fri Feb 29, 2008 2:49 am

Here is 1 possible SYNCTOOL solution:
//S1    EXEC  PGM=SYNCTOOL   
//TOOLMSG DD SYSOUT=*       
//DFSMSG  DD SYSOUT=*       
//IN1 DD DSN=TRGE09.FIRST
//IN2 DD DSN=TRGE09.SECOND               
//T1 DD DSN=&&T1,UNIT=SYSDA,SPACE=(CYL,(5,5)),DISP=(MOD,PASS)
//OUT1 DD DSN=TGRE09.OUT1
//OUT2 DD DSN=TGRE09.OUT2
//TOOLIN DD *                                                 
COPY FROM(IN1) TO(T1) USING(CTL1)                             
COPY FROM(IN2) TO(T1) USING(CTL2)                             
SPLICE FROM(T1) TO(OUT1) ON(21,8,ZD) WITH(11,10) USING(CTL3)   
SPLICE FROM(T1) TO(OUT2) ON(21,8,ZD) WITH(11,10) USING(CTL4)   
/*                                                           
//CTL1CNTL DD *                                               
  INREC BUILD=(1,10,21:SEQNUM,8,ZD)                           
/*                                                           
//CTL2CNTL DD *                                               
  INREC BUILD=(11:1,10,21:SEQNUM,8,ZD)                         
/*                                                           
//CTL3CNTL DD *                                               
  OUTFIL FNAMES=OUT1,INCLUDE=(1,10,ZD,LE,11,10,ZD),OUTREC=(1,10) 
/*                                                           
//CTL4CNTL DD *                                               
  OUTFIL FNAMES=OUT2,INCLUDE=(11,10,ZD,LT,1,10,ZD),OUTREC=(11,10) 
/*

However, I think that a SyncSort JOIN application may also suit your needs. Let me kow if you are interested.
Alissa Margulies
Syncsort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
Alissa Margulies
Global moderator
 
Posts: 369
Joined: Tue Feb 26, 2008 11:15 pm
Location: USA
Has thanked: 1 time
Been thanked: 1 time

Re: some help in synctool

Postby fazillatheef » Fri Feb 29, 2008 10:55 am

Thank you
fazillatheef
 
Posts: 18
Joined: Mon Feb 25, 2008 12:50 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to Syncsort/Synctool

 


  • Related topics
    Replies
    Views
    Last post