Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Why do a TBOPEN DUMMY?

Status
Not open for further replies.

gm333

MIS
Feb 3, 2010
2
US
I have found several REXX/ISPF coding examples where a TBOPEN DUMMY was done. However, I can't find anything in any REXX or ISPF manual as to why someone would want to execute a command like that. Can anyone shed some light on this? Here's an example:

ADDRESS ISPEXEC 'TBEND MYTABLE';
ADDRESS ISPEXEC 'CONTROL ERRORS RETURN';
ADDRESS ISPEXEC 'TBCLOSE MYTABLE LIBRARY(USRTBL)';
ADDRESS ISPEXEC 'TBOPEN DUMMY LIBRARY(DUMMY)';
ADDRESS ISPEXEC 'CONTROL ERRORS CANCEL';
 
The technique is used to force the table LIBRARY closed when the LIBRARY parameter was used to TBOPEN a table.

Avoid this entirely by
Code:
address ISPEXEC 
"LIBDEF  ISPTLIB  DATASET  ID("isptlib")  STACK" 
"TBOPEN" tabl_name "WRITE"
"LIBDEF  ISPTLIB"

This loads your table library at the head of the list so that the TBOPEN finds the table there, then immediately purges the LIBDEF. No allocations, no enqueues, no hassles.


Frank Clarke
--America's source for adverse opinions since 1943.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top