Subject: RE: CICS VSAM File Access Techniques
From: Chris Behrends (CBehrends@MACCnet.com)
Date: Wed Nov 11 2009 - 12:57:00 EST
We have several files like this and the way you described it is the best way to do it that I know of. I have a common program for VSAM access that makes all of this easier for development.
Chris Behrends
Software Engineer
Mid America Computer Corporation (MACC)
Phone: 402-533-5405
CBehrends@maccnet.com
From: owner-vse-l@Lehigh.EDU [mailto:owner-vse-l@Lehigh.EDU] On Behalf Of industrynews@winwholesale.com
Sent: Wednesday, November 11, 2009 11:07 AM
To: VSE Discussion List
Subject: CICS VSAM File Access Techniques
When you have a multi-part key, where the last part of the key is some kind of sequence field, I've found that I can easily go directly to the last record in the file but I cannot (so easily) go directly to the last record in a given sequence of records. Is this at all possible? Meaning...
To go directly to the last record in the file requires a completely high-value key and a STARTBR EQUAL (which results in EIBRESP=0) followed by a READPREV which succeeds in retrieving the last record in the file.
To go directly to the last record in a given sequence of records, I tried setting the first part of the key to the value for the desired group of records and setting the sequence field to high-values. However, in this case, the STARTBR EQUAL results in NOTFND (EIBRESP=13) and the READPREV, of course, then results in INVREQ (EIBRESP=16).
Am I forced, in this case, to set the first part of the key to the value for the desired group of records, set the sequence field to all 9's, and then use STARTBR GTEQ followed by READNEXT and two READPREV? ...and, then, have to have a special case if I hit the end of file on the READNEXT?
Anybody follow all that?
Sincerely,
Dave Clark
WinWholesale Group Services
3110 Kettering Boulevard
Dayton, Ohio 45439 USA
(937) 294-5331
This email message and any attachments is for use only by the named addressee(s) and may contain confidential, privileged and/or proprietary information. If you have received this message in error, please immediately notify the sender and delete and destroy the message and all copies. All unauthorized direct or indirect use or disclosure of this message is strictly prohibited. No right to confidentiality or privilege is waived or lost by any error in transmission.
________________________________
Confidentiality Notice: The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you receive this in error, please contact the sender and delete the material from any computer.
This archive was generated by hypermail 2b25 : Sat Nov 21 2009 - 13:20:07 EST