16.20 - Use-default-conn - 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

Use-default-conn is a one byte EBCDIC field that indicates whether a connection being established by an External Stored Procedure calling CLIv2 and executing in the Teradata Database is a new connection or the connection used by the application to call the procedure.

Use-default-conn exists only when DBCHINI had been called for a DBCAREA with Total-length set to at least 640 (that is, the returned DBCAREA Level value is at least 1). For a smaller DBCAREA, Use-default-conn is ignored.

In this language... The variable name for Use-default-conn is...
COBOL USE-DEFAULT-CONN
PL/I USE_DEFAULT_CONN
C, C++ useDefaultConn
IBM Assembler DBCNIDC
This routine... Does this for...
DBCHINI writes
DBCHCL reads (CON; IRQ; IWPF)
Use-default-conn is used by... To..
applications write

One of the following values may be set before initiating a request:

If... Then set Connect-type to...
'N', indicates that a new connection is established.
  • DBC-NO for COBOL
  • DBC_DFLT_CONN_NO for PL/I)
  • DBC_DfltConnNo for C and C++
  • DBCNIDCN for Assembler
'Y', indicates that the connection used to call the procedure is used.
  • DBC-YES for COBOL
  • DBC_DFLT_CONN_YES for PL/I
  • DBC_DfltConnYes for C and C++
  • DBCNIDCY for Assembler

If not specified 'N' is assumed.

If Use-default-conn is set to 'Y', since a new connection is not being established, the following DBCAREA settings that would normally apply to the Connect function are ignored: Connect-type, Delegate-user-identity, input-TDP-pat, Logon-length, Logon-pointer, Mechanism-data-encoding, Mechanism-data-len, Mechanism-data-ptr, Mechanism-name, Run-length, and Run-pointer.

If Use-default-conn is set to 'Y' since session-wide settings from the existing connection are used, the following DBCAREA options that would normally apply to the Connect function are ignored: Date-form, Language-conformance, Statement-status, Transaction-semantics, and Two-phase commit.

For details on External Stored Procedures, refer to Stored Procedures.