Variable Length Fetch - Call-Level Interface Version 2

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

Product
Call-Level Interface Version 2
Release Number
15.00
Language
English (United States)
Last Update
2018-09-25
dita:id
B035-2418
lifecycle
previous
Product Category
Teradata Tools and Utilities

Variable Length Fetch

Usage Notes

The Variable Length Fetch field specifies the location of the length information for the data made available from the response.

 

Language

Variable Name

COBOL:

DBCAREA-VAR-LEN-FETCH

C: DBCAREA.H:

var_len_fetch

 

Routine

Action Taken

DBCHINI:

writes

DBCHCL:

reads (CON; RSUP: IRQ)

 

Used by

Action Taken

application program

writes

Variable Length Fetch is initialized by DBCHINI to the default value provided for Variable Length Fetch in the site’s SPB.

If the value provided is not appropriate for the application, before calling DBCHCL for the Connect, Run Startup, or Initiate Request function, the application program may set:

  • Change Options to Y, and
  • Variable Length Fetch to:
  • Y, if the length information is to immediately precede the string to which it applies.
  • N, if the length information is to be supplied separately from the string to which it applies.
  • For a parcel of data made available by DBCHCL from the response, DBCHCL supplies to the application program both the length and the address of the data.

    If Variable Length Fetch is set to N the address in Fetch Data Pointer points to the beginning of the parcel body and the length of the parcel body is supplied separately in Fetch Returned Data Length.

    If Variable Length Fetch is set to Y, the address in Fetch Data Pointer points to a two-byte length (in binary) field which precedes the parcel body, and the length of the parcel body is not supplied in Fetch Returned Data Length.

    Only set Variable Length Fetch to Y if Parcel Mode Fetch is set to Y.

    Do not set both Variable Length Fetch and Locate Mode to Y.