16.20 - Changing the Value for Wait-for-response - Teradata Tools and Utilities

Teradata® Call-Level Interface Version 2 Reference for Mainframe-Attached Systems

prodname
Teradata Tools and Utilities
vrm_release
16.20
created_date
September 2019
category
Programming Reference
featnum
B035-2417-108K
When the value for Wait-for-response is not appropriate for the application, you should perform the following procedure before calling DBCHCL.
  1. Set Change-options to 'Y'.
  2. Change the value for Wait-for-response as follows.
    If DBCHCL is... Then change the value for Wait-for-response to...
    not to return control until it is able to initiate or complete Y
    to return control as soon as the function‘s request has been sent to the Teradata Database, in which case the application must use some other method to detect when the function‘s response arrives N

Use mnemonics for the codes. Mnemonics are provided in the language definition file for the DBCAREA.

If Wait-for-response is set to N, and one of the two situations described earlier occurs, the return code is set to 150.

The application may try again. There are two ways to decide when it is reasonable to perform a retry.
  • Call DBCHWAT.

    When control is returned from DBCHWAT, try again. This method ties up fewer system resources while waiting.

    Several tries may be necessary.

    Occasionally CLIv2 may finish one operation and start another immediately.

    In that case, DBCHWAT will return control when one operation is over, but the next call by the application to DBCHCL will not be accepted because CLIv2 has already started another operation.

    Allow for the possibility of multiple tries.

  • Try again immediately and keep trying until the call is accepted.

    If you use this method, there should be a time delay coded between fetch attempts.

    • If one of the two situations above occurs and Wait-for-response is set to N, the original call to DBCHCL was not accepted. CLIv2 is reporting, “I was not able to do that; try again later.”

      Wait-for-response set to 'Y' is incompatible with the use of a master ECB and will result in an error return code.

    • Neither the Abort function nor the Disconnect function is affected by the setting of Wait-for-response.