Changing the Value for Wait For Response|CLIv2 - Changing the Value for Wait for Response - Call-Level Interface Version 2

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

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
Lake
VMware
Product
Call-Level Interface Version 2
Release Number
20.00
Published
January 2024
Language
English (United States)
Last Update
2024-05-14
dita:mapPath
bmn1691484839905.ditamap
dita:ditavalPath
obe1474387269547.ditaval
dita:id
fvz1470444150352
Product Category
Teradata Tools and Utilities
If the value provided is not appropriate for the application, before calling DBCHCL, the application program may set:
  1. Change Options to 'Y'.
  2. Change the Wait For Response value to the appropriate value:
    • 'Y'[, if DBCHCL is not to return control until it can initiate or complete.
    • 'N', if DBCHCL is to return control as soon as the function’s request has been sent to the database, in which case the application program must use some other method to detect when the function’s response arrives.

If Wait For Response is set to 'N' and one of the two situations described here occurs, the following return codes are given:

EM_NOTIDLE (208) or EM_NODATA (211),
The application program may try again.
  • The first way to decide when it is reasonable to try again is to call DBCHWAT. When control is returned from DBCHWAT, try again. This method ties up less system resources while waiting.

    Several tries may be necessary. Occasionally CLI may finish one operation it is doing and go on to another immediately. In that case, DBCHWAT will return control when one operation is over, but the application program’s next call to DBCHCL “does not go through” because CLI has already started another operation. Allow for the possibility of multiple tries.

  • The second way to decide when it is reasonable to try again is to try again immediately, and keep trying until “the call gets through.”
  • If one of these situations occurs and Wait For Response is set to 'N', the original call to DBCHCL did not “take” at all. CLI is reporting “I was not able to do that; try again later.”
  • Neither the Abort function nor the Disconnect function is affected by the setting of Wait For Response.

The Fetch, Rewind, End Request, and Abort functions read and use the value of Wait For Response, but do not store it.

By using Wait for Response during CLI logoff processing, applications can prevent CLI from waiting “forever” if the gateway does not respond to the logoff request.