SQLCARD command (X'2408')

The distributed data management (DDM) architecture SQL Descriptor Area Row Description with SQL Communications Area command (SQLCARD) provides metadata information about the columns being retrieved along with the communications area.

Format

Read syntax diagramSkip visual syntax diagramDSSHDRLLCPSQLCAGRP

Parameters

DSSHDR
The 6-byte header field containing information about the DSS.
LL
A 2-byte field that has the length of the SQLCARD command.
CP(X'2408')
The 2-byte code point of the SQLCARD command.
SQLCAGRP
SQL Communications Area Group Description.

Format:

Read syntax diagramSkip visual syntax diagramFLAGSQLCODESQLSTATESQLERRPROC SQLCAXGRPSQLDIAGGRP

Parameters:

FLAG
A 1-byte field that determines if the value for the SQLCAGRP is null. A null indicator is denoted with the value X'FF'.
SQLCODE
A 4-byte integer field that contains the return code that is sent by the database manager after completion of each SQL statement.
SQLSTATE
A 5-byte character field that contains the outcome of the most recently executed SQL statement.
SQLERRPROC
An 8-byte character field that contains the name of the CSECT that detected the error reported by the SQLIMSCODE.
SQLCAXGRP
SQL Communications Area Exceptions Group Description.

Format:

Read syntax diagramSkip visual syntax diagramFLAGSQLERRDSQLWARNSQLRDBNAME SQLERRMSG_mSQLERRMSG_s

Parameters:

FLAG
A 1-byte field that determines if the value for the SQLCAXGRP is null. A null indicator is denoted with the value X'FF'.
SQLERRD
Six 1-byte integer fields whose values are used to diagnose error conditions
SQLWARN
Eleven 1-byte character fields that represents SQLIMSWARN0 to SQLIMSWARNA.
SQLRDBNAME
A variable character string that shows the name of the remote database.
SQLERRMSG_m
A variable character string that contains one or more tokens, separated by X'FF', that are substituted for variables in the descriptions of error conditions. It may contain truncated tokens. A message length of 70 bytes indicates a possible truncation.
SQLERRMSG_s
A variable character string that contains one or more tokens, separated by X'FF', that are substituted for variables in the descriptions of error conditions. It may contain truncated tokens. A message length of 70 bytes indicates a possible truncation.
SQLDIAGGRP
SQL Descriptor Optional Group Description

Format:

Read syntax diagramSkip visual syntax diagramFLAGSQLDIAGSTTSQLDIAGCISQLDIAGCN

Parameters:

FLAG
A 1-byte field that determines if the value for the SQLCAXGRP is null. A null indicator is denoted with the value X'FF'.
SQLDIAGSTT
SQL Diagnostics Statement Group Description.
SQLDIAGCI
SQL Diagnostics Condition Information Array.
SQLDIAGCN
SQL Diagnostics Connection Array.

SQLCARD examples

The following example shows SQLCARD that is part of the request to an OPNQRY call.

[ibm][ims][drda][t4]        RECEIVE BUFFER: SQLCARD             (ASCII)           (EBCDIC)
[ibm][ims][drda][t4] 0000   0059D05300030053  2408006400000030  .Y.S...S$..d...0  ..}.............
[ibm][ims][drda][t4] 0010   3230303053514C52  4930314600010004  2000SQLRI01F....  ......<.........
[ibm][ims][drda][t4] 0020   8001000000000000  0000000000000000  ................  ................
[ibm][ims][drda][t4] 0030   0000000000202020  2020202020202020  .....             ................
[ibm][ims][drda][t4] 0040   001253414D504C45  2020202020202020  ..SAMPLE          ....(&<.........
[ibm][ims][drda][t4] 0050   2020202000000000  FF