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

Reading ESDS file randomly in Cobol Batch program


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
abdul

EXPERT


Joined: 28 Jul 2003
Posts: 23
Location: Bangalore,India

PostPosted: Tue Nov 18, 2003 7:48 am
Reply with quote

Hi,
Is there anyway to read ESDS file randomly in Cobol Batch program.Can we read it using RBA? If yes how? and if you can provide me any reference program that will be appreciated.

Thanks
Abdul
Back to top
View user's profile Send private message
mdtendulkar

Active User


Joined: 29 Jul 2003
Posts: 237
Location: USA

PostPosted: Tue Nov 18, 2003 12:35 pm
Reply with quote

Hello abdul,

there are 2 secnarios for this question.

1) The file is not sorted.
In this case you can not read the ESDS file randomly

2) The file is sorted on some key.
I think you can read the file randomly by using START command.
With the help of START command, you can point to the specific record using a key and then read sequentially.
Hope this helps.

Regards

Mayuresh Tendulkar[/u]
Back to top
View user's profile Send private message
Johore

Specialist


Joined: 12 Sep 2003
Posts: 19

PostPosted: Fri Nov 21, 2003 12:37 pm
Reply with quote

Hi ,

Entry-sequenced data sets are accessed by address, either sequentially or directly.When addressed sequential processing is used to process records in ascending relative byte address (RBA) sequence, VSAM automatically retrieves records in stored sequence.
To access a record directly from an entry-sequenced data set, you must supply the RBA for the record as a search argument.
Skip-sequential processing is not supported for entry-sequenced data sets.

Skip- Sequential is use of START to locate a key and then reading sequentilally.

Hope this helps
johore
Back to top
View user's profile Send private message
yashu_mys

New User


Joined: 09 Nov 2003
Posts: 4
Location: India

PostPosted: Thu Feb 19, 2004 12:07 pm
Reply with quote

Hi ,
For RBA i think one needs PL/1 , cobol doesn't support RBA right..?
Thanks ,
Yashvanth .
Back to top
View user's profile Send private message
bluebird

Active User


Joined: 03 Feb 2004
Posts: 127

PostPosted: Thu Feb 19, 2004 12:57 pm
Reply with quote

on your question :
did u check in IBM manuals ?
Back to top
View user's profile Send private message
xzsymr

New User


Joined: 06 Jun 2003
Posts: 7
Location: NZ

PostPosted: Wed Feb 25, 2004 11:33 am
Reply with quote

Yes it is possible to read a ESDS randomly, You can define an alternate index, just like in a KSDS and use that as the path etc to access the file randomly
Back to top
View user's profile Send private message
Ananya

New User


Joined: 26 Feb 2004
Posts: 19
Location: Chennai

PostPosted: Sat Mar 06, 2004 1:56 pm
Reply with quote

Dear Tendulkar,

Can START verb be used in ESDS?? are you sure about this? I don't think this is possible... but anyways,if I'm wrong pls correct me icon_cry.gif

Cheers
-Ananya
Back to top
View user's profile Send private message
sai_dd

New User


Joined: 01 Aug 2005
Posts: 5
Location: Cyprus

PostPosted: Mon Aug 01, 2005 7:02 pm
Reply with quote

We can use START verb for accessing an ESDS file in a normal COBOL program too.

COBOL Syntax:


START <COBOL File name> ...

Sai
Back to top
View user's profile Send private message
kiran.v2

New User


Joined: 29 Jul 2005
Posts: 9

PostPosted: Fri Oct 07, 2005 3:08 pm
Reply with quote

hi
in this case we can use search verb for accessing the sequential file randomly
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 -> DFSORT/ICETOOL

 


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 Replace each space in cobol string wi... COBOL Programming 3
Search our Forums:

Back to Top