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

Reading sequential file


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
umanaga

New User


Joined: 09 Apr 2007
Posts: 33
Location: India

PostPosted: Thu Jan 03, 2008 11:15 am
Reply with quote

Hi,
Is it possible to read sequential file in COBOL using a key.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Thu Jan 03, 2008 11:27 am
Reply with quote

Umanaga,

Quote:
Is it possible to read sequential file in COBOL using a key.

Random access - No.
Back to top
View user's profile Send private message
kbalajie

New User


Joined: 07 Apr 2006
Posts: 1

PostPosted: Thu Jan 03, 2008 12:15 pm
Reply with quote

Hi,

A sequential file can be accessed only sequentially and it is organized sequentially. We cannot read it through a key.

If you want to do some operation for a particular row using the key value which you have assigned, then you have to read the file sequentially and use a "if" or "evaluate" to pick a particular row sequentially.

Again I am insisting there is no way you can read the sequential file using the key.

Thanks & Regards,
Balaji
Back to top
View user's profile Send private message
balajiofcrrcoe

New User


Joined: 07 Jul 2005
Posts: 41
Location: chennai

PostPosted: Thu Jan 03, 2008 12:28 pm
Reply with quote

One suggestion...If the record count is less you can load the seq file into an array and use it as a table..
Back to top
View user's profile Send private message
Max Payne

New User


Joined: 13 Dec 2007
Posts: 10
Location: Shanghai

PostPosted: Fri Jan 04, 2008 7:40 am
Reply with quote

Sequential File can only be accessed by sequential read.
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 -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 2
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top