1.First two records are not duplicate. So why are they missing in output?
2."11245622017-03-03" is a duplicate so why is that even present in the output when you said you don't want duplicates at all?
3. Please do some research next time as this is being very common problem discussed several times on this forum.
4. SELECT with NODUPS.
If 1st part of key, 3126789 is same as next record, but dates are different..exclude both records from process. if dates are also same..then include only one record from that.
Below was my solution.
in 1st step I used below SORT
Code:
SORT FIELDS=(01,4,CH,A, /* COMP NO
05,09,CH,A, /* COMP NO
14,10,CH,D) /* DATE
SUM FIELDS=NONE,XSUM
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
bshkris,
Thanks for posting your solution. But the sort positions in the control cards does not seem to correspond to the sample data posted earlier? - the key seemed to be of length=7, but your control cards use a 13 byte key (COMP NO).
Looks like you have Syncsort, AFAIK DFSORT does not support the XSUM parameter. Topic will be moved to the correct forum.
I have another block with SORT.
I need to append the message to my input record. The out file have 250 bytes length.
Now, I want add( I/p rec + message).
I have my SORT card as below.
SORT FIELDS=COPY
OUTREC FIELDS=(1,23,1Z,
C'- 2 OR MORE SCHD DRILL RECORDS FOR THE SAME CCT NO, CPY NO WERE',
C'RECEIVED WITH THE SAME DRILL DATE ONCE REC WAS ACCEPTED.')
END
But the above one is syntax issue.
Please throw some ideas how we can add the multiple line messages to a record using SORT.
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
For a new problem start a new thread. And use the code tags or we won't know where to start. And cut and paste your sysout - using the code tags.
This topic is being locked.