Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Using ICETOOL to splice on more than 1 field

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
arnab

New User


Joined: 13 Mar 2006
Posts: 59
Location: UK

PostPosted: Thu May 31, 2007 11:42 am    Post subject: Using ICETOOL to splice on more than 1 field
Reply with quote

Hi,

I have a requirement to to use two files as input and get the new records (unique) from the second file. I could do this using ICETOOL splice operator but I can do so on one field only. Please see the details below.

File1 and File2 have same layout (LRECl=22). the layout is given below. I want to get only those records of FILE2 that are not present in FILE1. (I dont need any duplicates of FILE2). To distinguish unique records of file2 from file 1 the following fields must be unique. -- WS-STORE , WS-LINE-NMBR, WS-MM ,WS-DD and WS-YR.

1 WS-OUTPUT-REC.
05 WS-STORE PIC S9(5) VALUE +0 COMP-3.
05 WS-MM PIC 9(2) VALUE ZEROS.
05 PIC X VALUE '/'.
05 WS-DD PIC 9(2) VALUE ZEROS.
05 PIC X VALUE '/'.
05 WS-YR PIC 9(4) VALUE ZEROS.
05 WS-LINE-NMBR PIC S9(5) VALUE +0 COMP-3.
05 WS-LINE-AMOUNT PIC S9(9)V99 VALUE +0 COMP-3.

If it was only I field I can do it using SPLICE , but how to SPLICE ON more than one fields.

I have the following TOOLIN for ICETOOL to pull records based on STORE only. Can u please modify it to Splice on the other fields as mentioned above?
//TOOLIN DD *
COPY FROM(IN1) TO(T1) USING(CTL1)
COPY FROM(IN2) TO(T1) USING(CTL2)
SPLICE FROM(T1) TO(OUT12) ON(1,3,PD) WITH(25,1) -
USING(CTL3) KEEPNODUPS
/*

Thank you.
//CTL1CNTL DD *
INREC OVERLAY=(24:C'11')
/*
//CTL2CNTL DD *
INREC OVERLAY=(24:C'22')
/*
//CTL3CNTL DD *
OUTFIL FNAMES=OUT12,INCLUDE=(22,2,CH,EQ,C'12'),BUILD=(1,20)
OUTFIL FNAMES=OUT1,INCLUDE=(22,2,CH,EQ,C'11'),BUILD=(1,20)
OUTFIL FNAMES=OUT2,INCLUDE=(22,2,CH,EQ,C'22'),BUILD=(1,20)
/*
Back to top
View user's profile Send private message

Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Thu May 31, 2007 11:45 am    Post subject:
Reply with quote

You can use multiple ON in SPLICE statement.
Back to top
View user's profile Send private message
arnab

New User


Joined: 13 Mar 2006
Posts: 59
Location: UK

PostPosted: Thu May 31, 2007 11:52 am    Post subject:
Reply with quote

Can u please give me the syntax?
Back to top
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Thu May 31, 2007 11:59 am    Post subject:
Reply with quote

SPLICE FROM(indd) TO(outdd) ON(p,m,f) ON(p,m,f) ON(p,m,f) -
WITH(p,m) ...

Refer to ibm site:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA10/6.13?DT=20050222160456
Back to top
View user's profile Send private message
arnab

New User


Joined: 13 Mar 2006
Posts: 59
Location: UK

PostPosted: Thu May 31, 2007 12:05 pm    Post subject:
Reply with quote

Thanks a lot Devzee.

It should work fine .

regards,
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


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

PostPosted: Thu May 31, 2007 8:17 pm    Post subject:
Reply with quote

arnab,

For complete details on the SPLICE operator of DFSORT's ICETOOL, see:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA20/6.13?DT=20060615185603

You can access all of the DFSORT books from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts INVALID FIELD OR CONSTANT IN SORTOF ?? Ron Klop DFSORT/ICETOOL 8 Wed Jan 11, 2017 3:44 pm
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 pm
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts How to split the records using the am... vnktrrd DFSORT/ICETOOL 24 Fri Oct 28, 2016 7:33 pm
No new posts Sort records based on numeric field. Alks SYNCSORT 2 Wed Oct 19, 2016 10:14 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us