CANCEL OPERATION

From VSI OpenVMS Wiki
Jump to: navigation, search

CANCEL_OPERATION is an operation that can be specified in the function field of the F$GETQUI() lexical function. It clears the context established by previous runs of F$GETQUI().

Example

In the example below, F$GETQUI() iterates over queues. The next call of the function would display the next queue int the list (an empty string in this case), but as the context was cleared, the first queue in the list is displayed again.


$ show queue
Batch queue MYBATCH, idle, on SMAN01::

Generic batch queue SYS$BATCH

$ a = f$getqui("display_queue","queue_name","*")
$ show sym a
  A = "MYBATCH"
$ a = f$getqui("display_queue","queue_name","*")
$ show sym a
  A = "SYS$BATCH"
$ a = f$getqui("CANCEL_OPERATION")
$ show sym a
  A = ""
$ a = f$getqui("display_queue","queue_name","*")
$ show sym a
  A = "MYBATCH"