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
 

 

Sequential File matching requirement by using DFSORT

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

New User


Joined: 27 Mar 2007
Posts: 13
Location: chennai

PostPosted: Wed Apr 18, 2007 10:02 pm    Post subject: Sequential File matching requirement by using DFSORT
Reply with quote

hello,
I have two sequential files for matching. The following is the requirement by using DFSORT:

Code:

File A      File B
FieldA      FieldA FieldB
A           A      1
B           A      2
C           B      3
            B      4
            C      5


When i match the above two files based on the field A. I need the Sequential file C in the below format.

Code:

File C
A           1      2
B           3      4
C           5


Can anyone please help me out?

Thanks.
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: Wed Apr 18, 2007 11:35 pm    Post subject:
Reply with quote

You need to give more information about what you want to do.

What is the RECFM and LRECL of fileA and fileB?

What is the starting position, length and format of fieldA in fileA and fields A and B in fileB?

Is field A unique in fileA (only one A, one B, etc). Are there only two records maximum with each field A value (e.g. A or A, A but not A, A, A)?

What do you want to do with fieldA values in fileA that have no match in fileB? What do you want to do with fieldA values in fileB that have no match in fileA?

A better example showing the actual fields in each file and all of the different variations would help.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed Apr 18, 2007 11:38 pm    Post subject:
Reply with quote

Hello,

Please start over. Your file "defiinitions" are not at all clear. Some may understand what you've said, but many will not.

Post the info as "Code" using the tab at the top of the reply panel and make sure that the files are separated. This will make your post more readable.
This
Quote:
File A File B
FieldA FieldA FieldB
A A 1
B A 2
C B 3
B 4
C 5
provides no consistancy. How many fields are really in each file (1, or 2 or ?)?
Back to top
View user's profile Send private message
manikanth_e

New User


Joined: 27 Mar 2007
Posts: 13
Location: chennai

PostPosted: Thu Apr 19, 2007 12:23 am    Post subject: Re: Sequential File matching requirement by using DFSORT
Reply with quote

Frank,
The below is the info you need:
RECFM and LRECL of FILE A and FILE B are same.
FieldA in FileA starts at position1 and ends at position9.
FieldA in FileB starts at position1 and ends at position9.
FieldB in FileB starts at position11 and ends at position20.
and,
FieldA in FileA is not unique (multiple As and multipe Bs can occur). There is nothing like two records maximum with each fieldA value. It may vary.

The below is the example:
Code:

FileA              FileB
FieldA            FieldA  FieldB
A                   A        1
A                   A        2
B                   A        3
B                   B        4 
B                     
C


FileA (lrecl - 50) can consists multiple rows with same value for fieldA.
FileB (lrecl - 50) can consists multiple rows with same value foe fieldA.
When FileA is matched on FileB based on the FieldA for retrieving FieldB of FileB. The below should be the output.
Code:

A    1     2     3
A    1     2     3
B    4
B    4
B    4
C

As C doesnt have the match on file B, no corresponding values are seen.

please let me know in case you need furthur details.


Thanks.
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 Apr 19, 2007 12:32 am    Post subject:
Reply with quote

I don't know of any way to do this with DFSORT/ICETOOL.
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 Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am
No new posts File processing vishwakotin Mainframe Interview Questions 9 Fri Apr 28, 2017 11:38 am
No new posts Occurrence of various strings within ... TS70363 JCL & VSAM 1 Thu Apr 27, 2017 8:18 pm


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