CICS Manual do Usuário - WRITEQ TS


Volta a página anterior

Volta ao Menu Principal


Desenvolvido por DORNELLES Carlos Alberto - Analista de Sistemas - Brasília DF. - cad_cobol@hotmail.com

WRITEQ TS

Writes data to a temporary storage queue.

Sintaxe:

Nota:
The LENGTH option is required with C or C++ programs when FROM is used.

Descrição:

WRITEQ TS stores temporary data (records) in a temporary storage queue that is in either main or auxiliary storage.
In the latter case, the queue can reside on a remote system.

Exemplos:

The following example shows how to write a record to a temporary storage queue that is in auxiliary storage:

     EXEC CICS WRITEQ TS
          QUEUE(UNIQNAME)
          FROM(MESSAGE)
          LENGTH(LENGTH)
          ITEM(DREF)
     END-EXEC

The following example shows how to update a record in a temporary storage queue that is in main storage:

     EXEC CICS WRITEQ TS
          QUEUE('TEMPQ1')
          FROM(DATAFLD)
          LENGTH(40)
          ITEM(ITEMFLD)
          REWRITE
          MAIN
     END-EXEC

Opções:

    AUXILIARY
  • Specifies that the temporary storage queue is on a direct access storage device in auxiliary storage.
    FROM(data-area)
  • Specifies the data that is to be written to temporary storage.
    ITEM(data-area)
  • Specifies a 16-bit binary field to be used for the item number that is assigned to the logical record in the queue.
  • If the REWRITE option is not specified, the data area receives the item (record) number that is assigned to this record in the queue.
  • If the record starts a new queue, the item number assigned is 1; subsequent item numbers follow on sequentially.
  • If the REWRITE option is specified, the data area specifies the item that is to be replaced in the queue.
    LENGTH(data-value)
  • Specifies, as a 16-bit binary value, the length of the data that is to be written.
  • See LENGTH for more information about using this option.
    MAIN
  • Specifies that the temporary storage queue is in main storage.
    NOSUSPEND
  • Specifies that the application program is not to be suspended if the NOSPACE condition occurs.
    QUEUE(name)
  • Specifies the symbolic name of the queue that is to be written to.
  • If the queue name appears in the Temporary Storage Definitions (TSD) and the entry is marked as remote, the request is shipped to a remote system.
  • The name of the remote queue is taken from the TSD entry.
  • For a description of how queue names are found by pattern matching, see the TXSeries for Multiplatforms Administration Reference.
  • When you write applications in COBOL, the name can be up to eight characters long, each of which can contain any bit pattern; and it must be unique within the CICS system.
  • Do not use X'FA' through X'FF' because the first character of the name; these characters are reserved for CICS use.
  • The same rules apply when using C or C++, except that the name must be a full eight characters in length.
  • Names that are less than eight characters should not be used.
  • The same rules apply when using PL/I, except that the name must be a full eight characters in length.
  • Names that are less than eight characters should not be used.
  • If a remote SYSID is specified, the queue is assumed to reside on a remote system irrespective of whether the name exists in the local TSD entry.
  • Otherwise, the TSD entry is used to determine whether the queue is on a local or a remote system.
    REWRITE
  • Specifies that the existing record in the queue is to be overwritten with the data that is provided.
  • If the REWRITE option is specified, the ITEM option must also be specified.
  • If the specified queue does not exist, the QIDERR condition occurs.
  • If the correct item within an existing queue cannot be found, the ITEMERR condition occurs and the data is not stored.
    SYSID(name)
  • Specifies on which CICS region the WRITEQ is to run.
  • The SYSID name has one through four characters.
  • For a full description of the SYSID option, refer to SYSID.
  • If the SYSID option is not specified, it defaults to the value that is in the RemoteSysId attribute of the TSD entry that is matched with the queue name that is requested in the QUEUE option.

Condições:

    INVREQ
  • Occurs if the specified queue is in doubt (that is, locked upon restart and awaiting transaction resolution).
  • Ação pré-definida: Terminates the task abnormally.
    IOERR
  • Occurs if an I/O error occurs during the temporary storage operation.
  • See Processing the IOERR condition for information about handling the IOERR condition.
  • IOERR can occur for recoverable auxiliary intrapartition TS queues if the file server has been restarted while CICS is still running.
  • Ação pré-definida: Terminates the task abnormally.
    ISCINVREQ
  • Occurs if the remote system indicates a failure that does not correspond to a known condition.
  • Ação pré-definida: Terminates the task abnormally.
    ITEMERR
  • Occurs for the following conditions:
    • The item number that is specified or implied by a WRITEQ TS command with the REWRITE option is not valid (that is, outside the range of entry numbers that are assigned for the queue).
    • The maximum number of items (32767) is exceeded.
  • Ação pré-definida: Terminates the task abnormally.
    LENGERR
  • Occurs if the LENGTH option specifies a negative or zero value for the length of the data that is to be written.
  • Ação pré-definida: Terminates the task abnormally.
    NOSPACE
  • Occurs if not enough space is available in temporary storage to contain the data.
  • Ação pré-definida: Suspend the task until space becomes available as it is released by other tasks; then return normally. (This default action can be overridden by the NOSUSPEND option.)
    NOTAUTH
  • Occurs for the following conditions:
    • When a resource security check is unsuccessful on QUEUE(name)
    • When SYSID is specified by a transaction that is defined with the RSLCheck attribute set to either internal or external
  • Ação pré-definida: Terminates the task abnormally.
    QIDERR
  • Occurs if the queue that is specified by a WRITEQ TS command with the REWRITE option cannot be found in either main or auxiliary storage.
  • Ação pré-definida: Terminates the task abnormally.
    SYSIDERR
  • Occurs if a problem with the communications configuration prevents the WRITEQ from proceeding. For example:
    • The connection that is named in the SYSID option is not the name of a Communications Definition (CD) entry.
    • The SYSID option references a CD entry that is incorrectly configured.
    • The SYSID option references a CD entry that is marked as out of service.
  • It can also occur if the connection to the remote system is closed.
  • This could be because the remote system is not available.
  • Ação pré-definida: Terminates the task abnormally.

Informações relacionadas:


© Copyright IBM Corp.