The LOB Block Pointer points to the LOB Aggregate Data Block. This is used to define the parameters to support the Smart LOB (SLOB) support from Client to Server. For client-to-server transfers, SLOB mode allows the application to decide whether the LOB data should be handled in an inline fashion or in deferred mode, regardless of whether the associated SQL indicates deferred mode. To use SLOB Client to Server, the application specifies the appropriate parameters in the Lob Aggregate Data (LAD) block which is anchored from the DBCAREA LOB Block Pointer.
LOB Block Pointer exists only when DBCHINI had been called for a DBCAREA with Total-length set to at least 1024 (that is, the returned DBCAREA Level value is at least 2). For a smaller DBCAREA, LOB Block Pointer is ignored.
Language |
LOB Aggregate Data Table Variable Names |
IBM Assembler |
DBCALAD LADLVL – Version number of this control block. Must be 1. LADRSVD – Must be zero LADLPR – Maximum number of LOBs per Row LADLTA – Pointer to LOB Data Table LADPON – Pointer to Parameter Order Table |
COBOL |
DBCALADC LEVEL LAD_RESERVED LOBS-PER-ROW LOB-DATA-TABLE-PTR LOB-PARAM-ORDER-TABLE-PTR |
C |
DBCALAD level ladReserved maxNumLOBsPerRow LOBDataTablePtr LOBParamOrderTablePtr |
PL/1 |
DBCALAD VERSION RESERVED LOBS_PER_ROW LOB_DATA_TABLE_PTR LOB_PARAM_ORDER_TABLE_PTR |
Routine |
Action for LOB Aggregate Block |
DBCHINI |
writes |
DBCHCL |
reads (CON:IRQ:IWPF) |
LOB Block is used by... |
Action for LOB Aggregate Block |
applications |
write |
Parameter Order Table (LADPON) points to a table that is comprised of a full word for each possible column (the value in LADLPR “Maximum number of LOBs per Row”). Each value indicates the column number in the query that is SLOB eligible, relative to 1.
LOB Data Table (LADLTA ) points to a row table. The row table has an entry for each row (if doing array operations) or one entry if not doing array operations. Each row table is LADLPR (“Maximum number of LOBs per Row”) wide. Each cell in the Row/Column table points to the LOB Data or zero if deferred processing is wanted regardless of size for a particular row/column.
As an example, if non-array operation (single row) that has 2 SLOB eligible fields, the 2nd and 4th columns, the LOB Aggregate Data table fields would look like:
LADLVL |
will always contain 1. The version number of this control block. |
LADRSVD |
will always contain zero. This field is unused. |
LADLPR |
will contain 2 (number of SLOB eligible columns). |
LADPON |
will point to a table with two entries, 2 and 4. |
LADLTA |
will point to a table that has two pointers, a pointer to the LOB data for column 2 and a pointer to the LOB data for column 4. |