I long ago gave up on QSAM making the DCB right. I think CLOSE does a 90%
job of restoring the DCB, and I know I ran into a situation where OPEN was
failing (for a legitimate reason) but leaving the DCB modified.

In any situation where I am reusing a DCB I always rebuild it from a model.
If you are writing reentrant code you pretty much need a model anyway, and
you need code to move it in before the first OPEN, why not move it in before
every OPEN?

Not an answer to the question you asked, but hopefully a practical solution.

> I always thought that the system took a copy of the pre-OPEN DCB

My *impression* is that there is no "copy" per se. I think any restore is
done field by field, making a 90% job much more likely.

Charles

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf
Of Greg Price
Sent: Tuesday, September 28, 2010 2:17 AM
To: [email protected]
Subject: CLOSE restore of DCB?

I always thought that the system took a copy
of the pre-OPEN DCB, and restored it after
CLOSE, with the possible exception of DCBBUFCB.

After an OPEN and CLOSE of an EXCP DCB, the
bits in DCBBFALN which flag the presence of a
DCBE address in DCBDCBE have been zeroed.

----------------------------------------------------------------------
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