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

Query on ICETOOL


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

New User


Joined: 23 Mar 2007
Posts: 35
Location: pune

PostPosted: Wed Jun 02, 2010 10:51 pm
Reply with quote

Hello All,

I have a requirement where there are 2 input files of LRECL=10 and key is 4 bytes long. I need an output file which will have
1. records from File 1 where the complete record is not present in File 2
2. records from File 2 where the key matches with File 1 but the non key is different
3. records which are common to both File 1 and File 2

For the input files,
We will not have duplicate records in the entire record length in any one input file


1ST FILE.

ABCD909090
DEFG126567
HIJKL000000
OPQR111111
UYTR567678
GTHY787878
JUTH565656
JGDR454545

2ND FILE:

UYTR888888
DEFG786543
JGDR345678

OUTPUT FILE:

ABCD909090
DEFG786543
HIJKL000000
OPQR111111
UYTR888888
GTHY787878
JUTH565656
JGDR345678

I was wondering if this is possible thru SORT/ICETOOL

Thanks,
TS
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Wed Jun 02, 2010 11:08 pm
Reply with quote

thunderstorm,

Do you want 3 different output files? or a single out put file?
Back to top
View user's profile Send private message
thunderstorm

New User


Joined: 23 Mar 2007
Posts: 35
Location: pune

PostPosted: Wed Jun 02, 2010 11:11 pm
Reply with quote

Kolusu,

Its a single output file containing all the 3 types

Thanks,
TS
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Wed Jun 02, 2010 11:23 pm
Reply with quote

thunderstorm,

Use the following DFSORT/ICETOOL JCL

Code:

//STEP0100 EXEC PGM=ICETOOL               
//TOOLMSG  DD SYSOUT=*                     
//DFSMSG   DD SYSOUT=*                     
//IN       DD DSN=Your input file1,DISP=SHR           
//         DD DSN=Your input file2,DISP=SHR           
//OUT      DD SYSOUT=*                     
//TOOLIN   DD *                           
  SELECT FROM(IN) TO(OUT) FIRST ON(1,4,CH)
//*
Back to top
View user's profile Send private message
thunderstorm

New User


Joined: 23 Mar 2007
Posts: 35
Location: pune

PostPosted: Wed Jun 02, 2010 11:30 pm
Reply with quote

using your icetool card , the below requirement is not getting met

2. records from File 2 where the key matches with File 1 but the non key is different
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Wed Jun 02, 2010 11:35 pm
Reply with quote

thunderstorm wrote:
using your icetool card , the below requirement is not getting met

2. records from File 2 where the key matches with File 1 but the non key is different


thunderstorm,

simply reverse the order of concatenation. Use file 2 first and file 1 next
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 RC query -Time column CA Products 3
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 Dynamically pass table name to a sele... DB2 2
Search our Forums:

Back to Top