IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

ICETOOL SPLICE Problem


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
cpuhawg

Active User


Joined: 14 Jun 2006
Posts: 331
Location: Jacksonville, FL

PostPosted: Tue Nov 25, 2008 11:56 pm
Reply with quote

I have two files that have been sort together and am having a problem finding the appropriate SPLICE control cards to have them merged.

Code:

----+----1----+----2----+----3----+----4----+----5----+----6----+----7
                            GROUP1            X           
FIELD1:AAAAAAAAAAAAAAAAAAAA:GROUP1  :RRRRRRRR:
FIELD1:BBBBBBBBBBBBBBBBBBBB:GROUP1  :RRRRRRRR:
FIELD1:CCCCCCCCCCCCCCCCCCCC:GROUP1  :AAAAAAAA:
FIELD1:DDDDDDDDDDDDDDDDDDDD:GROUP2  :UUUUUUUU:
FIELD1:EEEEEEEEEEEEEEEEEEEE:GROUP2  :AAAAAAAA:
FIELD1:FFFFFFFFFFFFFFFFFFFF:GROUP2  :RRRRRRRR:
                            GROUP3            Y           
FIELD2:GGGGGGGGGGGGGGGGGGGG:GROUP3  :RRRRRRRR:
FIELD2:HHHHHHHHHHHHHHHHHHHH:GROUP3  :RRRRRRRR:
FIELD3:IIIIIIIIIIIIIIIIIIII:GROUP4  :RRRRRRRR:
FIELD3:JJJJJJJJJJJJJJJJJJJJ:GROUP4  :UUUUUUUU:


I want match on "GROUP? " in positions 29-36 and if they match..... the "X" or "Y" in position 47 should overlay the matched records. I also want to keep all the other records intact. The problem I am having is the records with GROUP2 or GROUP4 attempt to SPLICE according to field 29-36 and I lose records.

Code:

----+----1----+----2----+----3----+----4----+----5----+----6----+----7
FIELD1:AAAAAAAAAAAAAAAAAAAA:GROUP1  :RRRRRRRR:X
FIELD1:BBBBBBBBBBBBBBBBBBBB:GROUP1  :RRRRRRRR:X
FIELD1:CCCCCCCCCCCCCCCCCCCC:GROUP1  :AAAAAAAA:X
FIELD1:DDDDDDDDDDDDDDDDDDDD:GROUP2  :UUUUUUUU:
FIELD1:EEEEEEEEEEEEEEEEEEEE:GROUP2  :AAAAAAAA:
FIELD1:FFFFFFFFFFFFFFFFFFFF:GROUP2  :RRRRRRRR:
FIELD2:GGGGGGGGGGGGGGGGGGGG:GROUP3  :RRRRRRRR:Y
FIELD2:HHHHHHHHHHHHHHHHHHHH:GROUP3  :RRRRRRRR:Y
FIELD3:IIIIIIIIIIIIIIIIIIII:GROUP4  :RRRRRRRR:
FIELD3:JJJJJJJJJJJJJJJJJJJJ:GROUP4  :UUUUUUUU:


Any suggestion or solution would be appreciated.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


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

PostPosted: Wed Nov 26, 2008 12:09 am
Reply with quote

You can use KEEPBASE to keep the first record of each group. According to your example, that would keep these records:

Code:

                            GROUP1            X
...
FIELD1:DDDDDDDDDDDDDDDDDDDD:GROUP2  :UUUUUUUU:
...
                            GROUP3            Y
...
FIELD3:IIIIIIIIIIIIIIIIIIII:GROUP4  :RRRRRRRR:


Now you can just use an appropriate OUTFIL OMIT to get rid of those first GROUP1 and GROUP3 records based on blanks in some position (e.g. 1-5).
Back to top
View user's profile Send private message
cpuhawg

Active User


Joined: 14 Jun 2006
Posts: 331
Location: Jacksonville, FL

PostPosted: Wed Nov 26, 2008 12:27 am
Reply with quote

KEEPBASE solved the primary problem, but I was still losing some records which turned out to be records that were not duplicates according to positions 29-36. I found an example on page 602 of the V1R8.0 DFSORT Application Programming Guide that suggested using KEEPNODUPS (with WITHALL and KEEPBASE) and now all records are accounted for.

Thank you for your help Frank and have a Happy Thanksgiving. Your assistance to this board is invaluable.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


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

PostPosted: Wed Nov 26, 2008 12:42 am
Reply with quote

Right. You need KEEPNODUPS for nondups. I'm glad you figured it out.

Thanks for the kind words and I wish you a Happy Thanksgiving as well.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Wed Nov 26, 2008 3:52 am
Reply with quote

Hi,

do you mind posting the code.


Thanks



Gerry
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts Map Vols and Problem Dataset All Other Mainframe Topics 2
No new posts Shift left VB record without x00 endi... DFSORT/ICETOOL 11
No new posts how to calculate SUM value for VB fil... DFSORT/ICETOOL 1
No new posts how to calculate SUM for VB file usin... JCL & VSAM 1
No new posts Null values are considered in Total c... DFSORT/ICETOOL 6
Search our Forums:

Back to Top