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
 

 

JCL for comparison of flat files of variable length

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
kayelan
Warnings : 1

New User


Joined: 01 Dec 2006
Posts: 13
Location: frankfurt

PostPosted: Fri Dec 01, 2006 8:15 pm    Post subject: JCL for comparison of flat files of variable length
Reply with quote

Hi everyone,

I hv 2 flat files of variable length and records > than 20000. Let me explain the file structure:
<Fixed part>+ <n* Variable parts>
Every record has a fixed part with n number of Variable parts extended after the fixed part.
Record Layout For example..
FIXED PART-----------| VAR PART 1 | VAR PART 2 | VAR PART 3 |:::::::::

Requirements:

1. Need to compare two files

2. No. of records in both the files differ
For ex., File-1 will have 20 records and File-2 will have 30 records. The utility has to pick up only the same records and neglect the rest.

3. There are certain exceptional fields in the file which are to be omitted for comparison. i.e., even if the specified field differs in both the files, it is assumed the records match exactly .

4. There is a key field in one of the variable part that acts as a starting point to map a record in one file to other file


Need a JCL to do all the steps mentioned above.

Kindly help
Back to top
View user's profile Send private message

PeD

Active User


Joined: 26 Nov 2005
Posts: 456
Location: Belgium

PostPosted: Fri Dec 01, 2006 11:55 pm    Post subject:
Reply with quote

Quote:
FIXED PART-----------| VAR PART 1 | VAR PART 2 | VAR PART 3 |:::::::::


How can the compare software determine the length of each variable part and its number?

Can you show records with fake data.
Back to top
View user's profile Send private message
kayelan
Warnings : 1

New User


Joined: 01 Dec 2006
Posts: 13
Location: frankfurt

PostPosted: Mon Dec 04, 2006 1:33 pm    Post subject:
Reply with quote

Record structure looks like following:

Fixed part - 20 bytes
Variable part-5 bytes
In Fixed part the last field will contain no. of Variable parts following it.

Ex:
abcdefghijklmnopqr0501aaa02bbb03ccc04ddd05eee

05 in red colour shows no. of Variable parts.
Green and Blus show the variable parts
Back to top
View user's profile Send private message
PeD

Active User


Joined: 26 Nov 2005
Posts: 456
Location: Belgium

PostPosted: Mon Dec 04, 2006 3:54 pm    Post subject:
Reply with quote

One more question : does any occurence of variable part is always fixed. I mean all VAR PART n have the same length.

The variable part of record is only conditionned by field with "05" in this case, but which can be "03", "07", etc ...
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts High CPU consumption Job using IAM fi... aswinir JCL & VSAM 15 Thu Dec 01, 2016 8:28 pm
No new posts SQZ pipe delimited file with 1 column... Rick Silvers DFSORT/ICETOOL 2 Sun Nov 06, 2016 8:11 pm
No new posts CICS NEW SIT PARAMETERS CICS BEHAVIOR... Kyle Carroll CICS 0 Fri Nov 04, 2016 11:55 pm
No new posts Match or compare two files in VB Format anatol DFSORT/ICETOOL 14 Thu Nov 03, 2016 7:41 pm
No new posts Joinkeys operation when key1 and key2... Susanta DFSORT/ICETOOL 5 Wed Nov 02, 2016 5:35 pm


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