What am I doing wrong?
/Scott Wheeler, Computer Sciences Corporation, Fort Worth TX
$ show queue/all ps_lps1c6
Generic printer queue PS_LPS1C6
Entry Jobname Username Blocks Status
----- ------- -------- ------ ------
100 MSCR4A$1 SELLERS 145 Holding
101 MTDCR4A$1 SELLERS 141 Holding
102 DTDCR4A$1 SELLERS 141 Holding
$ diff release_held.com nl: ! 'type' with line #s.
************
File USER4:[WHEELER]RELEASE_HELD.COM;1
1 $Start: ! Release all 'Holding' jobs from PS_LPS1C6 queue.
2 $ ClearContext = F$GETQUI("CANCEL_OPERATION")
3 $QLoop:
4 $ QName = -
5 F$GETQUI("DISPLAY_QUEUE","QUEUE_NAME","PS_LPS1C6",-
6 "GENERIC,SYMBIONT")
7 $ IF QName .EQS. "" THEN EXIT
8 $JobLoop:
9 $ Held = F$GETQUI("DISPLAY_JOB","JOB_HOLDING",,"ALL_JOBS")
10 $ IF Held .EQS. "" THEN GOTO QLoop
11 $ Entry = -
12 F$GETQUI("DISPLAY_JOB","ENTRY_NUMBER",,-
13 "FREEZE_CONTEXT,ALL_JOBS")
14 $ IF Held .EQS. "TRUE" THEN SET ENTRY 'Entry'/RELEASE
15 $ GOTO JobLoop
******
File NL:[]RELEASE_HELD.COM;
************
Number of difference sections found: 1
Number of difference records found: 15
DIFFERENCES /IGNORE=()/MERGED=1-
USER4:[WHEELER]RELEASE_HELD.COM;1-
NL:[]RELEASE_HELD.COM;
$ @release_held
%JBC-E-NOQUECTX, no queue context
$
I think it's the second execution of the QName= statement after the
final GOTO Qloop !
Thomas
fwhe...@csc.com wrote:
--
Thomas H. Pauli, Hammersteinstr.19, 14199 Berlin, Germany
Your first problem is that the DISPLAY_JOB in line 9 has no context.
You're probably thinking, "Yes it does, I used DISPLAY_QUEUE first."
You're close. You need the WILDCARD flag in the DISPLAY_QUEUE call in
line 6. This "establishes and saves a context" according to the help.
If you had a wildcard character in the queue spec, you wouldn't need
the WILDCARD flag.
Your second problem is that you're using a SET ENTRY command before
you're done with your F$GETQUI calls. The SET ENTRY command wipes out
your current GETQUI context. You'd need to accumulate entry numbers
until you're done, then use SET ENTRY at the end.
--
Jim Becker
The Urban Institute (http://www.urban.org/)
Encompass (http://www.encompassus.org/)
ESILUG (http://encompasserve.org/lugs/esilug/)