Page 1 of 2

Remove particular records from Syncsort

PostPosted: Wed Nov 23, 2011 11:23 am
by meena
how to remove particular 5th,9th,11th record from the input file using syncsort.. i'm using SYNCTOOL RELEASE 1.6.0 so my version is not supporting icetool's subset/datasort commands.. kindly suggest some way

Re: syncsort

PostPosted: Wed Nov 23, 2011 12:19 pm
by dick scherrer
Hello,

Try appending an sequence number when readking the data and OMITing the sequence numbers you do not want in the outp

See if this helps:
syncsort-synctool/topic11.html#p5411

Re: syncsort

PostPosted: Wed Nov 23, 2011 12:20 pm
by NicC
If it is a SYNCSORT solution you are wanting why not post in the Syncsort part of the forum? This is the JCL part - Job Control Language - something completely different.

Re: syncsort

PostPosted: Wed Nov 23, 2011 1:12 pm
by Anuj Dhawan
meena wrote:how to remove particular 5th,9th,11th record from the input file using syncsort.. i'm using SYNCTOOL RELEASE 1.6.0 so my version is not supporting icetool's subset/datasort commands.. kindly suggest some way
This is doable, there are some working examples also in this forum; however, if you are looking for an exact answer, you need to a better job in explainng the requirements.

Do you have only 11 records in input file? Out of which you want to copy 5th,9th,11th records? What should be the next record in output - 15th? Is it a one time task - looks like no, as you want to do it using SyncSort. So what is the LRECL, RECFM of input an output?

Suggest you show some sample input and the expected output from that as well.

Re: syncsort

PostPosted: Wed Nov 23, 2011 2:26 pm
by meena
i'm having some lakhs of records in the input file(nacha format)... i need to delete depending upon the needs..sometimes i need to delete 50th record or 1009th record..so i tried to write a jcl with a utility to delete the mentioned record no..i came accross icetool-->subset functionality..but i'm in need of syncsort..
hi dick,
since so many records are there using seqno is a good way?
kindly give me the soln

Re: syncsort

PostPosted: Wed Nov 23, 2011 8:30 pm
by NicC
What is 'nacha' format? I only know of FB and VB for record types and PS, PDS, PDSE, VSAM etc for dataset types.

Re: syncsort

PostPosted: Wed Nov 23, 2011 8:38 pm
by Akatsukami
NicC wrote:What is 'nacha' format?

It's the Electronic Payments Association.

Re: syncsort

PostPosted: Wed Nov 23, 2011 8:42 pm
by BillyBoyo
Can you tell us what you are trying to achieve by deleting such records?

Re: syncsort

PostPosted: Thu Nov 24, 2011 1:35 am
by dick scherrer
Hello,

Can you tell us what you are trying to achieve by deleting such records?

They have been bad and are no longer permitted to participate. . . Or they will cause problems if processed and are being remove before the problem process.

Scary but it is better to remove a problem and have a successful run (say the payroll), document the action taken, and hopefully correct the code that caused/allowed the problem before the next run.

since so many records are there using seqno is a good way?
Why would it not be?

Re: syncsort

PostPosted: Thu Nov 24, 2011 9:44 am
by meena
hi dick,

i tried as u said but its giving error...i did the same wit sort but in two steps....can you suggest the sysin part for synsort in one step...my file recleng is 94...