MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Compare data in two files using REXX

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
arunkumar_e
Beginner


Joined: 06 May 2004
Posts: 27
Topics: 16
Location: Bangalore

PostPosted: Wed Mar 02, 2005 12:49 am    Post subject: Compare data in two files using REXX Reply with quote

Hi Friends,
I am new to the REXX programming, I want to compare two GDGs
say GDG 'A' and GDG 'B'.

Code:
A            B
------     --------
A1  a      A1   b
A3  a      A2   b
A4  a      A3   b
           A4   b

now using GDG 'B' i have to write a new file say FILE1 dropping all the rows corresponding to that in GDG 'A' by comparing only the values in the first column.

That is in FILE1 i need to have only A2 b.

is this possible using REXX.

Please let me know

Thanks
Arun
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12375
Topics: 75
Location: San Jose

PostPosted: Wed Mar 02, 2005 1:09 pm    Post subject: Reply with quote

arunkumar_e,

Was there any specific reason why you chose rexx? It can be done by utilities like Sort.

Let me know if you are interested

Thanks

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
arunkumar_e
Beginner


Joined: 06 May 2004
Posts: 27
Topics: 16
Location: Bangalore

PostPosted: Wed Mar 02, 2005 10:58 pm    Post subject: Reply with quote

Thanks for your response kolusu. please let me know how do we achieve this using sort.


Thanks,
Arun
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12375
Topics: 75
Location: San Jose

PostPosted: Thu Mar 03, 2005 8:45 am    Post subject: Reply with quote

arunkumar_e,

Please provide me with the following details.

1. What is the LRECL/RECFM of gdg 'A' & gdg 'B'?

2. What is the position and format of the key to be compared?

3. Does any of the files have duplicates?

4. What is the default sort product at your shop?

Thanks

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
arunkumar_e
Beginner


Joined: 06 May 2004
Posts: 27
Topics: 16
Location: Bangalore

PostPosted: Mon Mar 07, 2005 12:24 am    Post subject: Reply with quote

Hi Kolusu ! I Solved the above mentioned problem using Rexx itself, Thanks for ur help.

Arun
_________________
Arun
"Genius is one percent inspiration and ninety-nine percent perspiration." -- Thomas A. Edison
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group