cancel
Showing results for 
Search instead for 
Did you mean: 

Queue info

 
Mulder_1
Frequent Advisor

Queue info

Hi,

$ jname=f$getqui("DISPLAY_JOB","JOB_NAME",,"ALL_JOBS")

returns me what I expect....

But jname followed by JOBH :
JOBH = f$getqui("DISPLAY_JOB","JOB_HOLDING",,"HOLDING_JOBS")

This returns me something different.

Please suggest.

Thanks
2 REPLIES 2
Jess Goodman
Esteemed Contributor

Re: Queue info

If you want the second F$GETQUI to return data about the same job as the first one, then you must use the FREEZE_CONTEXT keyword.

JOBH = f$getqui("DISPLAY_JOB","JOB_HOLDING",,"HOLDING_JOBS,FREEZE_CONTEXT")

The DISPLAY_JOB function by default returns data for queues in a loop; a new queue on each call (null string returned if no more queues).
I have one, but it's personal.
Jess Goodman
Esteemed Contributor

Re: Queue info

Sorry, cut and paste error - you do not need the HOLDING_JOBS keyword, just the FREEZE_CONTEXT keyword, to return information about the same job.

JOBH = f$getqui("DISPLAY_JOB","JOB_HOLDING",,"FREEZE_CONTEXT")

And if what you were trying was to use HOLDING_JOBS instead of ALL_JOBS for the first DISPLAY_JOB call on a job, then you need to use BOTH. Without ALL_JOBS only jobs that are under your user name are returned.

JOBH = f$getqui("DISPLAY_JOB","JOB_HOLDING",,"ALL_JOBS,HOLDING_JOBS")
I have one, but it's personal.