Isn't this available from the catalog?  You might be able to get what you 
want using the SHOWCAT macro.




"Stephen M. Wiegand" <[EMAIL PROTECTED]> 
Sent by: IBM Mainframe Discussion List <[email protected]>
02/08/2006 03:59 PM
Please respond to
IBM Mainframe Discussion List <[email protected]>


To
[email protected]
cc

Subject
READPREV in batch






In CICS you can do a STARTBR on a VSAM KSDS or ESDS file and then 
issue a READPREV to get the previous record from the key you started 
at.  However, this function is not available to COBOL or IBM 
Assembler in batch.  We have an issue where we need to know what the 
last RBA is in an ESDS file.  It would be nice if we could do a 
STARTBR with a key of high-values and then do a READPREV.

Has only via the mother of invention, found a way to do this that is 
fast?  I know we could do a startbr at the begging or somewhere in 
the middle, do READNEXT saving off the keys until we hit EOF at which 
point the saved key would be the highest RBA.  But we have a huge 
file and this way would take too much time.

Thanks in advance for any suggestions.

Steve Wiegand

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to