开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

POWER/VS "DISP=I" (insert) JECL


 

FYI: I can't recall whether I've ever mentioned this before or not, but in case I haven't, I just wanted to pass along a handy helpful tip to those DOS/VS(E) geeks out there who might not already know about POWER/VS's little know (but incredibly handy!) "DISP=I" JECL command:


POWER/VS "DISP=I" (insert)


Example job stream to catalog the "A." source for a macro,
and then also automatically catalog the "edited" E deck too
via the little know but incredibly handy POWER/VS "DISP=I"
JECL command (DISP=I means "insert", as in "automatically
insert the specified spooled device output back into the
card reader"). Note the "DISP=I" usage on the "* $$ PUN"
punch card midway through the below job stream where punched
output is normally spooled:


* $$ JOB JNM=BAS,CLASS=0
* $$ LST CLASS=A
// JOB BAS CATALS A.BAS
// ASSGN SYS001,SYSRES
// ASSGN SYS002,SYSRES
// EXEC MAINT
CATALS A.BAS
BKEND
MACRO
&BAS BAS &R14,&SUBRTN
&BAS DC 0H'0',X'4D',AL.4(&R14,0),S(&SUBRTN)
MEND
BKEND
/*
/&
* $$ PUN CLASS=A,DISP=I
// JOB BAS EDECK ASSEMBLY A.BAS TO E.BAS
// ASSGN SYSLST,IGN
// OPTION DECK
// EXEC ASSEMBLY
PUNCH '* $$ JOB JNM=BAS,CLASS=0,DISP=D'
PUNCH '* $$ LST CLASS=A,DISP=D'
PUNCH '// JOB BAS CATALS E.BAS EDITED MACRO'
PUNCH '// EXEC MAINT'
END
/*
// RESET SYSLST
// OPTION EDECK,NODECK
// EXEC ASSEMBLY
COPY BAS
END
/*
// ASSGN SYSLST,IGN
// OPTION DECK
// EXEC ASSEMBLY
PUNCH '/*'
PUNCH '/&&'
PUNCH '* $$ EOJ'
END
/*
/&
* $$ EOJ



The end result is, the macro is automatically cataloged to BOTH
the A. and E. source sublibraries with one simple submission of
a simple job stream. There is NO NEED to manually capture the
punched output from // OPTION EDECK assembly and then manually
wrap it with JCL and manually submit it to catalog the "edited"
macro to the E. sublibrary. Instead, by simply using a "DISP=I"
JECL card, it is done for you automatically in one job stream!


--
"Fish" (David B. Trout)
Software Development Laboratories

mail: fish@...