Geeks Talk

Prepare for your Next Interview




I want to move matching records from both files to file-C

This is a discussion on I want to move matching records from both files to file-C within the MainFrame forums, part of the Software Development category; File-A and File-B have 10 records and I want to move matching records from both the files in file-C and non-matching records in file-D? Without ...


Go Back   Geeks Talk > Software Development > MainFrame

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 06-18-2007
Expert Member
 
Join Date: Feb 2007
Posts: 1,279
Thanks: 0
Thanked 164 Times in 138 Posts
Geek_Guest is on a distinguished roadGeek_Guest is on a distinguished road
I want to move matching records from both files to file-C

File-A and File-B have 10 records and I want to move matching records from both the files in file-C and non-matching records in file-D?
Without sorting the both input files.
ALL FILES ARE PS.

Question asked by visitor Alok
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-07-2007
Junior Member
 
Join Date: Jul 2007
Location: India
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
sachina2z is on a distinguished road
Re: I want to move matching records from both files to file-C

I am replying with simple pseudo code bellow, plz work on it.

Read records of File-A one by one and chk it with all records of File-B.
If it matches then write to File-C else write to File-D.
Reply With Quote
  #3 (permalink)  
Old 08-02-2007
Junior Member
 
Join Date: Feb 2007
Location: Bangalore
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
srinivashn82 is on a distinguished road
Re: I want to move matching records from both files to file-C

Quote:
Originally Posted by Geek_Guest View Post
File-A and File-B have 10 records and I want to move matching records from both the files in file-C and non-matching records in file-D?
Without sorting the both input files.
ALL FILES ARE PS.

Question asked by visitor Alok
The only way you can do this by writing the cobol program. Where the frist record in file A should be compared with rest of the record in File B. if matching found then write the record to C after writing delete the record form the both Files A and B.

After this step is over . you are left with only unmatching records in both the files . So write them to file D.
Reply With Quote
Reply

  Geeks Talk > Software Development > MainFrame


Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
Control file syntax to transfer data from multiple data files Geek_Guest Oracle Apps 0 06-14-2007 11:35 AM
The system cannot move the file to a different disk drive chitravallivenkat Data Warehousing 0 05-23-2007 02:25 AM
Can anyone write this Matching Logic? zyxwv MainFrame 0 05-16-2007 07:06 PM
File Defender - protect your files from unauthorized access with ease! JobHelper Geeks Lounge 0 04-17-2007 06:50 AM
How many 4Test Script files should be present in the Suit file S1. JobHelper SilkTest 0 12-28-2006 06:03 AM


All times are GMT -4. The time now is 12:50 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2008 GeekInterview.com. All Rights Reserved