George said: > Given these JCL statements:
>//OUT01A OUTPUT CLASS=R,WRITER=W1,FORMS=F000 >//OUT01 DD SYSOUT=(,), OUTPUT=(*,OUT01A) >//OUT02A OUTPUT CLASS=R,WRITER=W1,FORMS=F999 >//OUT02 DD SYSOUT=(,), OUTPUT=(*,OUT02A) >What I am trying to do is to dynamically change the WRITER used for the >OUT01 DD from W1 to W2 within an assembler program. > My program gets control before the OUT01 file has been opened. I >was thinking that I could get to the PDDB control block before the JOE >is built for the file, and change it there prior to opening it, but I >haven't been able to get to the PDDB. Does anyone know if this will work >and how I can get to the PDDB? > This is not a JES exit. It sounds like a lot of unnecessary work. I assume your data or environment determines which writer you want. If your program is simply chosing between two writers, then use two separate sysout DDs. Write to the one with the correct writer name. On the other hand, if your program needs more flexibilty, such as to change the writer based on an unknown number of possibilities, then it would be simpler to use the documented interface for dynamic allocation. I believe you can find information about that in the authorized assembler programmer guide/reference. ---------------------------------------------------------------------- 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

