TAA Tools
CLROUTQ2        CLEAR OUTPUT QUEUE 2                   TAASPOR

The Clear Output Queue  2 command clears all but a  specified number of
spooled  files from  an  output queue.    The spooled  files  are first
sorted  in descending  sequence by open  date/time.   The spooled files
are then  read, the specified  number are  bypassed, and the  remainder
are  deleted.   CLROUTQ2  simplifies  keeping an  output  queue with  a
manageable number of spooled files.

You  must be authorized to  access the output  queue and delete spooled
files from it.

A typical command would be:

             CLROUTQ2   OUTQ(xxx) NBR(15)

All spooled files would  be deleted except for  the 15 most current  in
the specified output queue.

Note that  the technique does  not consider  the status of  the spooled
files.  A spooled file being written or held may be deleted.

Required authority
------------------

You may use CLROUTQ2 on an output queue if:

  **   You have *SPLCTL special authority

  **   The   output  queue  specifies  AUTCHK(*DTAAUT)   and  you  have
       *JOBCTL special authority.

  **   The output  queue  specifies  AUTCHK(*OWNER)  and  you  are  the
       owner.

       If an individual  spooled file in  the output queue is  owned by
       a  user  other than  yourself,  you  must  have *JOBCTL  special
       authority to delete the spooled file.

CLROUTQ2 escape messages you can monitor for
--------------------------------------------

      TAA9893    One or more errors occurred.

Escape messages from based on functions will be re-sent.

CLROUTQ2 Command parameters                           *CMD
---------------------------

   OUTQ          The  qualified  name  of the  output  queue  to delete
                 from.    The library  value  defaults  to  *LIBL.    A
                 specific library or *CURLIB may also be used.

   NBRRTN        The number  of spooled  files to be  retained.   10 is
                 the  default.    The  number  must  be  between 0  and
                 9999999.


Restrictions
------------

You must be authorized  to access the output  queue and delete  spooled
files from it.

Prerequisites
-------------

The following TAA Tools must be on your system:

     CHKJOBCTL       Check *JOBCTL special authority
     CHKOBJ3         Check object 3
     CVTOUTQ         Convert output queue
     EDTVAR          Edit variable
     RSNLSTMSG       Resend last message
     RTVOUTQA        Retrieve output queue attributes
     RTVSPCAUT       Retrieve special authority
     SNDCOMPMSG      Send completion message
     SNDDIAGMSG      Send diagnostic message
     SNDESCINF       Send escape information
     SNDESCMSG       Send escape message
     SNDSTSMSG       Send status message
     SORTDBF         Sort data base file

Implementation
--------------

None, the tool is ready to use.

Objects used by the tool
------------------------

   Object        Type    Attribute      Src member    Src file
   ------        ----    ---------      ----------    ----------

   CLROUTQ2      *CMD                   TAASPOR       QATTCMD
   TAASPORC      *PGM       CLP         TAASPORC      QATTCL
					

Added to TAA Productivity tools January 15, 2009


Home Page Up to Top