ibm-information-center/dist/eclipse/plugins/i5OS.ic.apis_5.4.0.1/xsqlci.htm

5634 lines
171 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation">
<title>SQL Client Integration Exit Program</title>
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<!-- Begin Header Records ========================================== -->
<!-- File SCRIPT A converted by B2H R4.1 (346) (CMS) by V2KEA304 -->
<!-- at RCHVMW2 on 17 Feb 1999 at 11:05:09 -->
<!--File Edited March 2001 -->
<!-- This file has undergone html cleanup on 1/10/02 by JET -->
<!--End Header Records -->
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
</head>
<body>
<a name="top_Of_Page"></a>
<!-- Java sync-link -->
<script language="Javascript" src="../rzahg/synch.js" type="text/javascript">
</script>
<h2>SQL Client Integration Exit Program</h2>
<div class="box" style="width: 75%;">
<br>
&nbsp;&nbsp;Required Parameter Group:<br>
<!-- iddvc RMBR -->
<br>
<table width="100%">
<tr>
<td align="center" valign="top" width="10%">1</td>
<td align="left" valign="top" width="50%">Interface level</td>
<td align="left" valign="top" width="20%">Input</td>
<td align="left" valign="top" width="20%">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">2</td>
<td align="left" valign="top">Input format</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">3</td>
<td align="left" valign="top">Length of input format</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="left" valign="top">Input format name</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Char(8)</td>
</tr>
<tr>
<td align="center" valign="top">5</td>
<td align="left" valign="top">SQLCA</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Char(136)</td>
</tr>
<tr>
<td align="center" valign="top">6</td>
<td align="left" valign="top">CCSID</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="top">7</td>
<td align="left" valign="top">Output format</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Char(*)</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="left" valign="top">Length of output format</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Binary(4)</td>
</tr>
</table>
<br>
&nbsp;&nbsp;QSYSINC Member Name: ERWSCI<br>
<!-- iddvc RMBR -->
<br>
</div>
<p>The SQL Client Integration exit program enables SQL applications to access
data managed by a database management system other than the i5/OS relational
database. An application requester driver (ARD) program is the generic term for
this type of exit program. The two terms are used interchangeably throughout
this topic. The system calls the ARD program during the following
operations:</p>
<ul>
<li>During the package creation step, performed by using the CRTSQLPKG or
CRTSQLxxx commands, when the relational database (RDB) parameter matches the
RDB name corresponding to the ARD program. During these calls, the system
passes information about the SQL statements and host variables contained in the
program. An ARD program can use this information to build what is comparable to
an SQL access plan for the program. SQL statements passed to the ARD program at
package creation can be correlated with the statement at run time by using the
package name, collection, consistency token, and section number of the
statement passed on the package creation and run-time interfaces.</li>
<li>During CONNECT processing when the RDB name specified on the CONNECT
statement matches the RDB name corresponding to the ARD program. During these
calls information about the environment the statements are to run under is
passed to the ARD program. An ARD program can use this information to establish
the environment for running statements of the program.</li>
<li>During processing of SQL statements when the current connection is to an
RDB name corresponding to the ARD program. During these calls, the system
passes information about the statement being run. An ARD program can either use
this information alone or use the information in conjunction with the package
name, collection, consistency token, and section number to process the SQL
statement.</li>
</ul>
<p>The CL commands that correspond to this exit program are the Add Relational
Database Directory Entry (ADDRDBDIRE) and the Change Relational Database
Directory Entry (CHGRBDDIRE) commands. Information about the ARD program must
be defined to the system by adding it to the RDB directory using the ADDRDBDIRE
command. Entries in the RDB directory that refer to ARD programs contain the
keyword *ARDPGM in the remote location field. Each entry must identify the
qualified ARD program name and the RDB name that it should be associated with.
Also stored in the RDB directory entry is the level of interface that the ARD
program expects to be called with. Currently the only value allowed is 1. An
ARD program can be defined to process requests for several different RDBs by
specifying the same ARD program for each RDB directory entry the ARD program is
to process.</p>
<br>
<h3>Restrictions</h3>
<p>The following operations are not allowed in the ARD program or any program
it calls:</p>
<ul>
<li>Commit operations for the commitment definition that is associated with the
statement that the ARD program is currently handling.</li>
<li>Rollback operations for the commitment definition that is associated with
the statement that the ARD program is currently handling.</li>
<li>End Commitment Control (ENDCMTCTL) command for the commitment definition
that is associated with the statement that the ARD program is currently
handling.</li>
<li>Any SQL statements. SQL statements encountered while an ARD program is
running will return messages SQLCODE (-84) and SQLSTATE (42612).</li>
</ul>
<p>DECLARE CURSOR statements must parse successfully on the application
requester to be used through this interface.</p>
<p>The ARD program must be in a
library that is part of the system auxiliary storage pool (ASP number 1) or a
configured basic ASP (ASP numbers 2-32).</p>
<p>The following functions are not supported for the SQL Client Integration
exit program interface:</p>
<ul>
<li>Database large objects (BLOBs, CLOBs, DBCLOBs)</li>
<li>Data links</li>
<li>Passwords longer than ten characters</li>
<li>Stored procedure result
sets</li>
<li>SQL statements longer than 32K</li>
<li>Stored procedures with Commit on Return</li>
<li>Scrollable cursors</li>
<li>Multi-row input</li>
<li>Extended diagnostics</li>
<li>User ids longer than 10 characters</li>
<li>RDB aliases</li>
</ul>
<br>
<h3>Required Parameter Group</h3>
<dl>
<dt><strong>Interface level</strong></dt>
<dd>INPUT; BINARY(4)
<p>The level of the ARD program. The only value that will currently be passed
is 1 because no value can be specified on the RDB directory commands. It is
possible that updates to the interface could be made in the future.</p>
<p>For example, such updates could include:</p>
<ul>
<li>Additional parameters.</li>
<li>Changes to the input format structures.</li>
<li>Changes to the SQLCA structure.</li>
<li>Changes to the SQLDA structure.</li>
<li>Changes to the output format structures.</li>
</ul>
<p>Changes to enumerated values without changes to a structure will not result
in a new interface level. Therefore, the ARD program should reject any
unexpected values in the input format structures, or in the input SQLDA
structure. In addition, the product identifier field on the ARCN0100 format can
be used to determine the level of the local database that also identifies the
values that could be expected for enumerated values in the input format and
SQLDA structure. If updates are made to the interface, it may be possible for
ARD programs to be registered with levels other than one by specifying the
level on the RDB directory commands. At such time, a user registering the ARD
program may incorrectly specify a level other than one for a program that only
understands the level one interface. Therefore, ARD programs written to
understand the current interface, the level one interface, should return an
error if a level other than one is passed.</p>
</dd>
<dt><strong>Input format</strong></dt>
<dd>INPUT; CHAR(*);
<p>The input format. The following table identifies the formats that the system
will pass to the ARD program for each of the input format name values.</p>
<p><strong>Note:</strong> General information on the nature of the functions
associated with the various input formats listed may be found in the
Distributed Relational Database Architecture Reference, SC26-4651. The chapter
about the DRDA processing model and command flows should be of particular
interest in this regard.</p>
</dd>
<!-- Note, however, that the SQL Client Integration (SCI)
implementation does not follow all of the DRDA data formats
described in the <cite>DRDA Reference</cite>. For example,
a block of query data for SCI has a simpler structure
because it does not include embedded SQLCA information
for each row. -->
<dd><strong><a name="Table_1-16">Relationship between Input Format Name and
Input Format</a></strong><br>
<br>
<table cellpadding="5" border>
<tr>
<th align="left" valign="bottom">Input Format Name</th>
<th align="left" valign="bottom">Input Format</th>
</tr>
<tr>
<td align="left" valign="top">ARCN0100</td>
<td align="left" valign="top">See <a href="#HDRCNFMT">Format ARCN0100 (Connect
Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARDI0100</td>
<td align="left" valign="top">See <a href="#HDRDIFMT">Format ARDI0100
(Disconnect Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARBB0100</td>
<td align="left" valign="top">See <a href="#HDRBBFMT">Format ARBB0100 (Begin
Package Bind Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARBS0100</td>
<td align="left" valign="top">See <a href="#HDRBSFMT">Format ARBS0100 (Bind
Statement for Package Creation Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">AREB0100</td>
<td align="left" valign="top">See <a href="#HDREBFMT">Format AREB0100 (End of
Package Bind Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARPS0100</td>
<td align="left" valign="top">See <a href="#HDRPSFMT">Formats ARPS0100 and
ARPD0100 (Prepare Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARPD0100</td>
<td align="left" valign="top">See <a href="#HDRPSFMT">Formats ARPS0100 and
ARPD0100 (Prepare Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARXD0100</td>
<td align="left" valign="top">See <a href="#HDRXDFMT">Formats ARXD0100 and
ARXB0100 (Execute Bound Statement)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARXB0100</td>
<td align="left" valign="top">See <a href="#HDRXDFMT">Formats ARXD0100 and
ARXB0100 (Execute Bound Statement)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARXP0100</td>
<td align="left" valign="top">See <a href="#HDRXPFMT">Format ARXP0100 (Execute
Prepared Statement)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARXI0100</td>
<td align="left" valign="top">See <a href="#HDRXIFMT">Format ARXI0100 (Execute
Immediate Statement Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">AROC0100</td>
<td align="left" valign="top">See <a href="#HDROCFMT">Format AROC0100 (Open
Cursor Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARFC0100</td>
<td align="left" valign="top">See <a href="#HDRFCFMT">Format ARFC0100 (Fetch
from a Cursor Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARCC0100</td>
<td align="left" valign="top">See <a href="#HDRCCFMT">Format ARCC0100 (Close a
Cursor Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARDS0100</td>
<td align="left" valign="top">See <a href="#HDRDSFMT">Format ARDS0100 (Describe
a Statement Format)</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARDT0100</td>
<td align="left" valign="top">See <a href="#HDRDTFMT">Format ARDT0100 (Describe
Object Format)</a>.</td>
</tr>
</table>
<br>
</dd>
<dt><strong>Length of input format</strong></dt>
<dd>INPUT; BINARY(4)
<p>The length of the input format in bytes.</p>
</dd>
<dt><strong>Input format name</strong></dt>
<dd>INPUT; CHAR(8)
<p>The format of the information passed to the ARD program. The possible format
names follow:</p>
<dl>
<dt><em>ARCN0100</em></dt>
<dd>Connect format. This format will be used by the system to pass information
to the ARD program when a user or application attempts to connect to an RDB
name corresponding to the ARD program. This format will always be passed to the
ARD program before any other formats for a given connection. If running under
commitment control, the system will register an RDB resource with commitment
control. However, the provider of the ARD program must also register with
commitment control using the commitment control APIs to be informed of commit
and rollback requests so that it processes those requests and closes cursors as
necessary. Refer to <a href="#HDRCMTAPI">Commit APIs</a> for a description of
how to use commitment control APIs with ARD programs. See <a href="#HDRCNFMT">
Format ARCN0100 (Connect Format)</a> for the structure of the input format that
the system will pass to the ARD program for this input format name. See <a
href="#HDROCNFMT">Output Connect Format</a> for the structure of the output
format that the ARD program must return to the system in response to this input
format name.</dd>
<dt><em>ARDI0100</em></dt>
<dd>Disconnect format. This format will be used by the system to pass
information to the ARD program when a user, application, or the system attempts
to disconnect from an RDB name that corresponds to the ARD program. See <a
href="#HDRDIFMT">Format ARDI0100 (Disconnect Format)</a> for the structure of
the input format that the system will pass to the ARD program for this input
format name. No output format is returned from ARD program for this input
format name.</dd>
<dt><em>ARBB0100</em></dt>
<dd>Begin package bind format. This format will be used by the system to pass
information to the ARD program when a user or application attempts to create a
package and specifies an RDB name corresponding to the ARD program. See <a
href="#HDRBBFMT">Format ARBB0100 (Begin Package Bind Format)</a> for the
structure of the input format that the system will pass to the ARD program for
this input format name. No output format is returned from the ARD program for
this input format name.</dd>
<dt><em>ARBS0100</em></dt>
<dd>Bind statement for package creation format. This format will be used by the
system to pass information about an SQL statement to the ARD program when a
user or application attempts to create a package and specifies an RDB name
corresponding to the ARD program. See <a href="#HDRBSFMT">Format ARBS0100 (Bind
Statement for Package Creation Format)</a> for the structure of the input
format that the system will pass to the ARD program for this input format name.
No output format is returned from ARD program for this input format name.</dd>
<dt><em>AREB0100</em></dt>
<dd>End of package bind format. This format will be used by the system to pass
information to the ARD program about the end-the-package-creation function when
a user or applications attempts to create a package and specifies an RDB name
that corresponds to the ARD program. See <a href="#HDREBFMT">Format AREB0100
(End of Package Bind Format)</a> for the structure of the input format that the
system will pass to the ARD program for this input format name. No output
format is returned from ARD program for this input format name.</dd>
<dt><em>ARPS0100</em></dt>
<dd>Prepare statement format. This format will be used by the system to pass
information about an SQL statement to the ARD program when an application
attempts to prepare a statement. See <a href="#HDRPSFMT">Formats ARPS0100 and
ARPD0100 (Prepare Format)</a> for the structure of the input format that the
system will pass to the ARD program for this input format name. No output
format is returned from ARD program for this input format name.</dd>
<dt><em>ARPD0100</em></dt>
<dd>Prepare and describe format. This format will be used by the system to pass
information about an SQL statement to the ARD program when an application
attempts to prepare a statement and expects a description of the prepared
statement to be returned into an SQL descriptor area (SQLDA). See <a href=
"#HDRPSFMT">Formats ARPS0100 and ARPD0100 (Prepare Format)</a> for the
structure of the input format that the system will pass to the ARD program for
this input format name. See <a href="#HDRSQDAFMT">SQLDA</a> for the structure
of the output format that the ARD program must return to the system in response
to this input format name.</dd>
<dt><em>ARXD0100</em></dt>
<dd>Execute bound statement that returns data format. This format will be used
by the system to pass information about an SQL statement to the ARD program
when an application attempts to execute a statement that expects data to be
returned and was bound at package creation time by a call to the ARD program
with format ARDSB001. An example of a statement that expects data to be
returned is a SELECT INTO statement. See <a href="#HDRXDFMT">Formats ARXD0100
and ARXB0100 (Execute Bound Statement)</a> for the structure of the input
format that the system will pass to the ARD program for this input format name.
See <a href="#HDROXDFMT">Output Execute Format</a> for the structure of the
output format that the ARD program must return to the system in response to
this input format name.</dd>
<dt><em>ARXB0100</em></dt>
<dd>Execute bound statement that does not return data format. This format will
be used by the system to pass information about an SQL statement to the ARD
program when an application attempts to execute a statement that does not
return data and was bound at package creation time by a call to the ARD program
with format ARDSB001. See <a href="#HDRXDFMT">Formats ARXD0100 and ARXB0100
(Execute Bound Statement)</a> for the structure of the input format that the
system will pass to the ARD program for this input format name. The output
format that the ARD program must return to the system in response to this input
format name is a character (CHAR(1)) field containing an indication of whether
the statement resulted in an update. An update is any operation that results in
a change to an object such that the object is under commitment control.
<p>Valid values follow:</p>
<blockquote>
<table cellpadding="5">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">The operation did not result in an update.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">An update occurred from the operation.</td>
</tr>
</table>
</blockquote>
<br>
</dd>
<dt><em>ARXP0100</em></dt>
<dd>Execute prepared statement format. This format will be used by the system
to pass information about an SQL statement to the ARD program when an
application attempts to execute a statement that was previously prepared by a
call to the ARD program with either format ARPS0100 or ARPD0100. See <a href=
"#HDRXPFMT">Format ARXP0100 (Execute Prepared Statement)</a> for the structure
of the input format that the system will pass to the ARD program for this input
format name. The output format that the ARD program must return to the system
in response to this input format name is a character (CHAR(1)) field containing
an indication of whether the statement resulted in an update. An update is any
operation that results in a change to an object such that the object is under
commitment control.
<p>Valid values follow:</p>
<blockquote>
<table cellpadding="5">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">The operation did not result in an update.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">An update occurred from the operation.</td>
</tr>
</table>
</blockquote>
<br>
</dd>
<dt><em>ARXI0100</em></dt>
<dd>Execute immediate statement format. This format will be used by the system
to pass information about an SQL statement to the ARD program when an
application attempts to execute a statement that was not previously prepared.
See <a href="#HDRXIFMT">Format ARXI0100 (Execute Immediate Statement
Format)</a> for the structure of the input format that the system will pass to
the ARD program for this input format name. The output format that the ARD
program must return to the system in response to this input format name is a
character (CHAR(1)) field that contains an indication of whether the statement
resulted in an update. An update is any operation that results in a change to
an object such that the object is under commitment control.
<p>Valid values follow:</p>
<blockquote>
<table cellpadding="5">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">The operation did not result in an update.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">An update occurred from the operation.</td>
</tr>
</table>
</blockquote>
<br>
</dd>
<dt><em>AROC0100</em></dt>
<dd>Open a cursor format. This format will be used by the system to pass
information about an SQL OPEN statement to the ARD program when an application
attempts to execute the statement. See <a href="#HDROCFMT">Format AROC0100
(Open Cursor Format)</a> for the structure of the input format that the system
will pass to the ARD program for this input format name. See <a href=
"#HDROOCFMT">Output Open Cursor Format</a> for the structure of the output
format that the ARD program must return to the system in response to this input
format name.</dd>
<dt><em>ARFC0100</em></dt>
<dd>Fetch from a cursor format. This format will be used by the system to pass
information about an SQL FETCH statement to the ARD program when an application
attempts to execute the statement. See <a href="#HDRFCFMT">Format ARFC0100
(Fetch from a Cursor Format)</a> for the structure of the input format the
system will pass to the ARD program for this input format name. See <a href=
"#HDROFCFMT">Output Fetch Cursor Format</a> for the structure of the output
format that the ARD program must return to the system in response to this input
format name.</dd>
<dt><em>ARCC0100</em></dt>
<dd>Close a cursor format. This format will be used by the system to pass
information about an SQL CLOSE statement to the ARD program when an application
attempts to execute the statement. See <a href="#HDRCCFMT">Format ARCC0100
(Close a Cursor Format)</a> for the structure of the input format that the
system will pass to the ARD program for this input format name. No output
format is returned from ARD program for this input format name.</dd>
<dt><em>ARDS0100</em></dt>
<dd>Describe an SQL statement format. This format will be used by the system to
pass information about an SQL DESCRIBE STATEMENT statement to the ARD program
when an application attempts to execute the statement. See <a href="#HDRDSFMT">
Format ARDS0100 (Describe a Statement Format)</a> for the structure of the
input format that the system will pass to the ARD program for this input format
name. See <a href="#HDRSQDAFMT">SQLDA</a> for the structure of the output
format that the ARD program must return to the system in response to this input
format name.</dd>
<dt><em>ARDT0100</em></dt>
<dd>Describe an SQL table format. This format will be used by the system to
pass information about an SQL DESCRIBE TABLE statement to the ARD program when
an application attempts to execute the statement. See <a href="#HDRDTFMT">
Format ARDT0100 (Describe Object Format)</a> for the structure of the input
format that the system will pass to the ARD program for this input format name.
See <a href="#HDRSQDAFMT">SQLDA</a> for the structure of the output format that
the ARD program must return to the system in response to this input format
name.</dd>
</dl>
<br>
</dd>
<dt><strong>SQLCA</strong></dt>
<dd>OUTPUT; CHAR(136)
<p>The SQL communication area. This is used for returning diagnostic
information. The format of the structure is standard, and can be included using
the INCLUDE SQLCA statement in an SQL program. The SQLCA has the following
fields (shown in the C-language format):</p>
<pre>
struct sqlca
{
unsigned char sqlcaid[8];
long sqlcabc;
long sqlcode;
short sqlerrml;
unsigned char sqlerrmc[70];
unsigned char sqlerrp[8];
long sqlerrd[6];
unsigned char sqlwarn[11];
unsigned char sqlstate[5];
};
</pre>
<p> Fields that must be set by the ARD program prior to returning follow:</p>
<br>
<table cellpadding="5">
<!-- cols="10 90" -->
<tr>
<td width="10%" valign="top"><em>sqlcaid</em></td>
<td width="90%" valign="top">An eye-catcher for diagnostic purposes. This must
be set to 'SQLCA'.</td>
</tr>
<tr>
<td valign="top"><em>sqlcabc</em></td>
<td valign="top">The byte length of the SQLCA. This must be set to 136.</td>
</tr>
<tr>
<td valign="top"><em>sqlcode</em></td>
<td valign="top">The SQL return code. If the sqlcode is 0, the statement
completed successfully although a warning may have occurred. If the sqlcode is
positive, the statement completed successfully but a warning occurred during
execution. If the sqlcode is negative, an error occurred while running the
statement. A discussion about setting the sqlcode to match a system message
identifier follows this list of fields.</td>
</tr>
<tr>
<td valign="top"><em>sqlerrp</em></td>
<td valign="top">The program that detected the error and built the SQLCA.</td>
</tr>
<tr>
<td valign="top"><em>sqlerrd[2]</em></td>
<td valign="top">The number of rows affected for successful INSERT, and DELETE
statements. This cannot be zero for INSERT, UPDATE, and DELETE statements when
the sqlstate is 00000.</td>
</tr>
<tr>
<td valign="top"><em>sqlstate</em></td>
<td valign="top">A return code field that indicates the outcome of the most
recently executed SQL statement. An sqlstate of 00000 indicates an unqualified
successful completion. ANS/ISO standard sqlstate values should be used and are
documented in the <a href="../sqlp/rbafykickoff.htm">DB2 UDB for iSeries SQL
Programming</a> topic in the Information center.</td>
</tr>
</table>
<br>
<p>Another field in the SQLCA, sqlerrmc, is used to return additional pertinent
information about the last statement run. Tokens in this field must be
separated by X'FF' to be interpreted properly.</p>
<p>Each sqlcode has a corresponding message in message file QSQLMSGin library
QSYS.For negative SQLCODEs and positive SQLCODEs other than +100, the
corresponding message for the SQLCODE will be put in the job log. In addition,
messages about how a statement ran are also put in the job log when running in
debug mode. An ARD program can determine if the application is running in debug
mode by using the debug APIs. The message ID is constructed by appending the
absolute value (5 digits) of the sqlcode to SQ and changing the third character
to L if the third character is a zero. For example, if the sqlcode is -501, the
message identifier is SQL0501. Each message may optionally have replacement
variables. These variables are placed in the sqlerrmc field of the SQLCA in the
previous paragraph. A Display Message Description (DSPMSGD) command or format
RTVM0300 of the Retrieve Message (QMHRTVM) API can be used to determine the
correct length and type for replacement variables for a particular message. The
sqlerrmc field for a message should be built up according to the field data for
that message. Refer to SQLCODEs and SQLSTATEs in the <a href=
"../sqlp/rbafykickoff.htm">DB2 UDB for iSeries SQL Programming</a> topic in the
Information Center for more information about SQLCODEs, SQLSTATEs, and their
meaning.</p>
</dd>
<dt><strong>CCSID</strong></dt>
<dd>OUTPUT; BINARY(4)
<p>The CCSID of the sqlerrm, sqlerrp, and sqlwarn fields in the SQLCA.</p>
</dd>
<dt><strong><a name="SPTOUTFMT">Output format</a></strong></dt>
<dd>OUTPUT; CHAR(*)
<p>The format of the information passed from the ARD program. The following
table identifies the formats that the ARD program must return for each of the
input format name values that the system will pass to it.<br>
</p>
<p><strong><a name="Table_1-17">Relationship between Input Format Name and
Output Format</a></strong></p>
<table cellpadding="5" border>
<tr>
<th align="left" valign="bottom">Input Format Name</th>
<th align="left" valign="bottom">Output Format</th>
</tr>
<tr>
<td align="left" valign="top">ARCN0100</td>
<td align="left" valign="top">See <a href="#HDROCNFMT">Output Connect
Format</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARDI0100</td>
<td align="left" valign="top">No output format.</td>
</tr>
<tr>
<td align="left" valign="top">ARBB0100</td>
<td align="left" valign="top">No output format.</td>
</tr>
<tr>
<td align="left" valign="top">ARBS0100</td>
<td align="left" valign="top">No output format.</td>
</tr>
<tr>
<td align="left" valign="top">AREB0100</td>
<td align="left" valign="top">No output format.</td>
</tr>
<tr>
<td align="left" valign="top">ARPS0100</td>
<td align="left" valign="top">No output format.</td>
</tr>
<tr>
<td align="left" valign="top">ARPD0100</td>
<td align="left" valign="top">See <a href="#HDRSQDAFMT">SQLDA</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARXD0100</td>
<td align="left" valign="top">See <a href="#HDROXDFMT">Output Execute
Format</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARXB0100</td>
<td align="left" valign="top">Update performed (see the description following
this table).</td>
</tr>
<tr>
<td align="left" valign="top">ARXP0100</td>
<td align="left" valign="top">Update performed (see the description following
this table).</td>
</tr>
<tr>
<td align="left" valign="top">ARXI0100</td>
<td align="left" valign="top">Update performed (see the description following
this table).</td>
</tr>
<tr>
<td align="left" valign="top">AROC0100</td>
<td align="left" valign="top">See <a href="#HDROOCFMT">Output Open Cursor
Format</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARFC0100</td>
<td align="left" valign="top">See <a href="#HDROFCFMT">Output Fetch Cursor
Format</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARCC0100</td>
<td align="left" valign="top">No output format.</td>
</tr>
<tr>
<td align="left" valign="top">ARDS0100</td>
<td align="left" valign="top">See <a href="#HDRSQDAFMT">SQLDA</a>.</td>
</tr>
<tr>
<td align="left" valign="top">ARDT0100</td>
<td align="left" valign="top">See <a href="#HDRSQDAFMT">SQLDA</a>.</td>
</tr>
</table>
<br>
<p><strong>Update performed.</strong> CHAR(1)</p>
<p>An indicator of whether the statement resulted in an update. An update is
any operation that results in a change to an object such that the object is
under commitment control. Valid values follow:</p>
<table cellpadding="5">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">The operation did not result in an update.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Update occurred from the operation.</td>
</tr>
</table>
</dd>
<dd><br>
</dd>
<dt><strong>Length of output format</strong></dt>
<dd>OUTPUT; BINARY(4)
<p>The length of the output format in bytes. This must be zero for the
following input format names: ARDI0100, ARBB0100, ARBS0100, AREB0100, ARPS0100,
and ARCC0100.</p>
</dd>
</dl>
<br>
<h3>Input Format Structures</h3>
<p>In the following structures, the CCSID of the character fields is the job
CCSID unless a specific CCSID field is included in the format for the
field.</p>
<br>
<h3><a name="HDRCNFMT">Format ARCN0100 (Connect Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Device name</td>
</tr>
<tr>
<td align="center" valign="top">36</td>
<td align="center" valign="top">24</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Mode name</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Remote location name</td>
</tr>
<tr>
<td align="center" valign="top">52</td>
<td align="center" valign="top">34</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Local location name</td>
</tr>
<tr>
<td align="center" valign="top">60</td>
<td align="center" valign="top">3C</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Remote network identifier</td>
</tr>
<tr>
<td align="center" valign="top">68</td>
<td align="center" valign="top">44</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">TPN name</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">User ID</td>
</tr>
<tr>
<td align="center" valign="top">86</td>
<td align="center" valign="top">56</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Password</td>
</tr>
<tr>
<td align="center" valign="top">96</td>
<td align="center" valign="top">60</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Product identifier</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARCN0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>Device name.</strong> The device name that is specified in the
directory entry. This will be blank if RMTLOCNAME(*ARDPGM) is specified for the
RDB directory entry.</p>
<p><strong>Local location name.</strong> The local location name that is
specified in the directory entry. This will be blank if RMTLOCNAME(*ARDPGM) is
specified for the RDB directory entry.</p>
<p><strong>Mode name.</strong> The mode name that is specified in the directory
entry. This will be blank if RMTLOCNAME(*ARDPGM) is specified for the RDB
directory entry.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> for a
description of the output format associated with this input format.</p>
<p><strong>Password.</strong> The password that the application or user
specified on the CONNECT statement. This field is blank if no password is
specified. The system does not verify that this password is correct.</p>
<p><strong>Product identifier.</strong> The product identifier for the local
database in the form QSQ<em>vvrrm</em>, where:</p>
<ul>
<li><em>vv</em> is a 2-digit version identifier such as 03.</li>
<li><em>rr</em> is a 2-digit release identifier such as 01.</li>
<li><em>m</em> is a 1-digit modification level such as 0.</li>
</ul>
<p>For example, if the local database is Version 3 Release 1 Modification 0 of
DB2/400, the product identifier is QSQ03010.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Remote location name.</strong> The remote location name that is
specified in the RDB directory entry. This will be *ARDPGM if
RMTLOCNAME(*ARDPGM) is specified for the RDB directory entry.</p>
<p><strong>Remote network identifier.</strong> The remote network identifier
that is specified in the directory entry. This will be blank if
RMTLOCNAME(*ARDPGM) is specified for the RDB directory entry.</p>
<p><strong>TPN name.</strong> The transaction program name that is specified in
the directory entry. This will be blank if RMTLOCNAME(*ARDPGM) is specified for
the RDB directory entry.</p>
<p><strong>User ID.</strong> The user identifier that the application or user
specified on the CONNECT statement. This field is blank if no user ID is
specified.</p>
<br>
<h3><a name="HDRDIFMT">Format ARDI0100 (Disconnect Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">28</td>
<td align="center" valign="top">1C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Disconnect type</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARDI0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong><a name="SPTDISCT">Disconnect type</a>.</strong> The system will set
this field to indicate the type of disconnection that is being performed.
Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>1</em></td>
<td width="95%" valign="top">Disconnection is occurring because the application
performed a DISCONNECT statement for only the relational database that the ARD
program is associated with or the application was compiled with the RDB
connection method of *RUW and it performed a CONNECT. If the ARD program
returns a negative SQLCODE, the disconnection fails and the connection is not
ended. The system will never pass this value to the ARD program if the ARD
program indicated the conversation uses a protected conversation on the
ARCN0100 format.</td>
</tr>
<tr>
<td valign="top"><em>2</em></td>
<td valign="top">Disconnection is occurring because a DISCONNECT ALL was
performed by the application or because all connections for the activation
group are ending by an implicit disconnection. Regardless of the SQLCODE value
returned by the ARD program, the connection will be ended. The system will
never pass this value to the ARD program if the ARD program indicated that the
conversation uses a protected conversation on the ARCN0100 format.</td>
</tr>
<tr>
<td valign="top"><em>3</em></td>
<td valign="top">Disconnection is occurring as part of a commit or rollback.
The connection is ending for one of the following reasons:<br>
<ul>
<li>The connection was released and a commit is being performed.</li>
<li>The SQL application ended.</li>
<li>The activation group ended.</li>
<li>An error was detected during an earlier call to the ARD program. The
connection had pending changes.</li>
</ul>
</td>
</tr>
<tr>
<td valign="top"><em>4</em></td>
<td valign="top">Disconnection is occurring because an error was detected
during an earlier call to the ARD program. Regardless of the SQLCODE value
returned by the ARD program, the connection will be ended.</td>
</tr>
</table>
<br>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by theARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> for a
description of the output format associated with this input format.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<br>
<h3><a name="HDRBBFMT">Format ARBB0100 (Begin Package Bind Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Existence required</td>
</tr>
<tr>
<td align="center" valign="top">77</td>
<td align="center" valign="top">4D</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Errors allowed</td>
</tr>
<tr>
<td align="center" valign="top">78</td>
<td align="center" valign="top">4E</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Replace allowed</td>
</tr>
<tr>
<td align="center" valign="top">79</td>
<td align="center" valign="top">4F</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Blocking type</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Default collection</td>
</tr>
<tr>
<td align="center" valign="top">130</td>
<td align="center" valign="top">82</td>
<td align="left" valign="top">CHAR(50)</td>
<td align="left" valign="top">Text</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARBB0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>Blocking type.</strong> An indicator of when blocking should be
performed for read-only cursors in the program. This value may be overridden on
the call to the ARD program with the AROC0100 format when the cursor is opened.
Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">Blocking is never performed.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Blocking is only performed for cursors declared FOR FETCH ONLY
or if there are no dynamic statements or positioned UPDATE or DELETE statements
for the cursor.</td>
</tr>
<tr>
<td valign="top"><em>2</em></td>
<td valign="top">Blocking is performed as long as the cursor is not declared
FOR UPDATE and there are no positioned UPDATE or DELETE statements for the
cursor.</td>
</tr>
</table>
<br>
<p><strong>CCSID.</strong> The CCSID of the text. This will always be set to
500.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>Default collection.</strong> The name of the collection identifier
that is used for the unqualified names of the tables, views, indexes, and SQL
packages. This parameter applies only to static SQL statements. A special value
of *NONE indicates no default collection.</p>
<p><strong>Errors allowed.</strong> Whether errors are allowed. Values passed
follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">All statements are checked for correct syntax and
semantics. If any error occurs, the package should not be created. When
processing the AREB0100 format and an error occurs, the ARD program should
return a negative sqlcode for any statement in error. When the AREB0100 format
is processed, the ARD program should return a negative sqlcode.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Even if errors occur while processing the statements, the
package should be created. Reserved sections should be generated for statements
in error. When processing the ARBS0100 format and an error occurs, the ARD
program should return a negative sqlcode for any statement in error. However,
when processing the AREB0100 format, the ARD program should return a
non-negative sqlcode.</td>
</tr>
</table>
<br>
<p><strong>Existence required.</strong> Whether existence of and authority to
an object is required. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">The absence of an object or lack of authority to
an object is not treated as an error. When processing the ARBS0100 format and
an object is not found or an authority error occurs, a non-negative sqlcode
should be returned from the ARD program in the SQLCA parameter.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">The absence of an object or lack of authority to an object is
treated as an error. When processing the ARBS0100 format and an object is not
found or an authority error occurs, a negative sqlcode should be returned from
the ARD program in the SQLCA parameter.</td>
</tr>
</table>
<br>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
</td>
</tr>
<tr>
<td valign="top"></td>
<td valign="top">Uncommitted changes in other jobs can be seen.</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
</td>
</tr>
<tr>
<td valign="top"></td>
<td valign="top">A row that is selected but not updated is locked until the
next row is selected. Uncommitted changes in other jobs cannot be seen.</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
</td>
</tr>
<tr>
<td valign="top"></td>
<td valign="top">Uncommitted changes in other jobs cannot be seen.</td>
</tr>
</table>
<br>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that is
being created. A collection is a name that provides a logical grouping for SQL
objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that is being created. Refer to <a href="#HDRCONTKN">Consistency
Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that is being
created.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Replace allowed.</strong> Whether the package can be replaced.
Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">The SQL package is not created if the SQL package
of the same name already exists in the specified collection. When processing
the AREB0100 format and the package with the same name already exists, the ARD
program returns a negative sqlcode.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">The SQL package is created and any existing SQL package of the
same name in the specified collection replaced. The authorities for the
existing SQL package are kept for the new SQL package.</td>
</tr>
</table>
<br>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>'</em></td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot; &quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Text.</strong> Text that briefly describes the packages
function.</p>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRBSFMT">Format ARBS0100 (Bind Statement for Package Creation
Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">84</td>
<td align="center" valign="top">54</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">88</td>
<td align="center" valign="top">58</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQL statement</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQL statement</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQLDA</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQL statement</td>
</tr>
</table>
<br>
<h3>Field Descriptions for Format ARBS0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the statement text.</p>
<p><strong>Length of SQLDA.</strong> The length of the SQLDA structure that
describes the host variables that are used on the statement. If zero, no host
variables were used on the statement.</p>
<p><strong>Length of SQL statement.</strong> The length of the SQL statement as
contained in the program.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Offset to SQLDA.</strong> The offset from the start of the input
format structure to the SQLDA structure that describes the host variables that
are used on the statement. If zero, no host variables were used on the
statement.</p>
<p><strong>Offset to SQL statement.</strong> The offset from the start of the
input format structure to the SQL statement as contained in the program.</p>
<p><strong>Package collection.</strong> The collection for the package being
created. A collection is a name that provides a logical grouping for SQL
objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package being created. Refer to <a href="#HDRCONTKN">Consistency Token</a> for
a description of this field.</p>
<p><strong>Package name.</strong> The name of the package being created.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number of the statement. Refer
to <a href="#HDRSECNUM">Section Number</a> for a description of this field.</p>
<p><strong>SQLDA.</strong> An SQLDA structure that describes the host variables
that are used on the statement. The SQLDA structure is described in <a href=
"#HDRSQDAFMT">SQLDA</a>. The SQLDATA and SQLIND pointers are set to NULL for
package creation.</p>
<p><strong>SQL statement.</strong> The SQL statement as contained in the
program except that <samp>:H</samp> has been substituted for the host variable
identifiers.</p>
<br>
<h3><a name="HDREBFMT">Format AREB0100 (End of Package Bind Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Maximum section number</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format AREB0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>Maximum section number.</strong> The last section number in the
package. This value may be greater than the last number passed on a call to the
ARD program with format ARBS0100 when section numbers are reserved. Refer to <a
href="#HDRSECNUM">Section Number</a> for more information on section
numbers.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package being
created. A collection is a name that provides a logical grouping for SQL
objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package being created. Refer to <a href="#HDRCONTKN">Consistency Token</a> for
a description of this field.</p>
<p><strong>Package name.</strong> The name of the package being created.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<br>
<h3><a name="HDRPSFMT">Formats ARPS0100 and ARPD0100 (Prepare Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQL statement</td>
</tr>
<tr>
<td align="center" valign="top">116</td>
<td align="center" valign="top">74</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQL statement</td>
</tr>
<tr>
<td align="center" valign="top">120</td>
<td align="center" valign="top">78</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Statement name</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQL statement</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Formats ARPS0100 and ARPD0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the statement text and statement
name.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
Uncommitted changes in other jobs can be seen.</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>A row that is selected but not updated is locked until the next row is
selected. Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
</table>
<br>
<p><strong>Length of SQL statement.</strong> The length of the statement string
being prepared.</p>
<p><strong>Offset to SQL statement.</strong> The offset from the start of the
input format structure to the statement string being prepared.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>SQL statement.</strong> The statement string being prepared.</p>
<p><strong>Statement name.</strong> The SQL statement name that is specified on
the PREPARE statement.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>'</em></td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRXDFMT">Formats ARXD0100 and ARXB0100 (Execute Bound
Statement)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Default collection</td>
</tr>
<tr>
<td align="center" valign="top">130</td>
<td align="center" valign="top">82</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">132</td>
<td align="center" valign="top">84</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to input SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">136</td>
<td align="center" valign="top">88</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of input SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">140</td>
<td align="center" valign="top">8C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQL statement</td>
</tr>
<tr>
<td align="center" valign="top">144</td>
<td align="center" valign="top">90</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQL statement</td>
</tr>
<tr>
<td align="center" valign="top">148</td>
<td align="center" valign="top">94</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to DECLARE PROCEDURE</td>
</tr>
<tr>
<td align="center" valign="top">152</td>
<td align="center" valign="top">98</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of DECLARE PROCEDURE</td>
</tr>
<tr>
<td align="center" valign="top">156</td>
<td align="center" valign="top">9C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to procedure name</td>
</tr>
<tr>
<td align="center" valign="top">160</td>
<td align="center" valign="top">A0</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of procedure name</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Input SQLDA</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQL statement</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">DECLARE PROCEDURE statement</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Procedure name</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Formats ARXD0100 and ARXB0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of statement text.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>DECLARE PROCEDURE statement.</strong> The DECLARE PROCEDURE
statement as contained in the program that is associated with the statement
when the statement is a CALL statement. 1403 class A</p>
<p><strong>Input SQLDA.</strong> An SQLDA structure that describes the host
variables that are used on the statement. The SQLDA structure is described in
the <a href="#HDRSQDAFMT">SQLDA</a>.</p>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs can be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>A row that is selected but not updated is locked until the next row is
selected. Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
</table>
<br>
<p><strong>Length of DECLARE PROCEDURE.</strong> If the statement being
executed is a CALL statement and if 1 was returned for the include bound
statements field when the ARD program was called using the ARCN0100 format,
this field is the length of the associated DECLARE PROCEDURE statement as
contained in the program. If there is no associated DECLARE PROCEDURE
statement, the statement is not a CALL statement or if 0 was returned for the
include bound statements field, this field is set to zero.</p>
<p><strong>Length of input SQLDA.</strong> The length of the SQLDA structure
that describes the input host variables that are used on the statement. If
zero, no input host variables were used on the statement.</p>
<p><strong>Length of procedure name.</strong> If the statement being executed
is a CALL statement, this field is the length of the procedure name. Otherwise,
this field is set to zero.</p>
<p><strong>Length of SQL statement.</strong> If the value 1 was returned for
the include bound statements field when the ARD program was called using the
ARCN0100 format, this field is the length of the statement as contained in the
program. Otherwise, this field is set to zero.</p>
<p><strong>Offset to DECLARE PROCEDURE.</strong> If the statement being
executed is a CALL statement and if 1 was returned for the include bound
statements field when the ARD program was called using the ARCN0100 format,
this field is the offset of the associated DECLARE PROCEDURE statement as
contained in the program. If there is no associated DECLARE PROCEDURE
statement, the statement is not a CALL statement, or if 0 was returned for the
include bound statements field, this field is set to zero.</p>
<p><strong>Offset to input SQLDA.</strong> The offset from the start of the
input format structure to the SQLDA structure that describes the input host
variables that are used on the statement. If zero, no input host variables were
used on the statement.</p>
<p><strong>Offset to procedure name.</strong> If the statement being executed
is a CALL statement, this field is the offset from the start of the input
format structure to the procedure name as contained in the CALL statement.
Otherwise, this field is set to zero.</p>
<p><strong>Offset to SQL statement.</strong> If 1 was returned for the include
bound statements field when the ARD program was called using the ARCN0100
format, this field is the offset from the start of the input format structure
to the SQL statement as contained in the program. Otherwise, this field is set
to zero.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>Procedure name.</strong> If the statement being executed is a CALL
statement, this field contains the procedure name as specified in the CALL
statement.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>SQL statement.</strong> The statement as contained in the
program.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top">'</td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRXPFMT">Format ARXP0100 (Execute Prepared Statement)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">116</td>
<td align="center" valign="top">74</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">120</td>
<td align="center" valign="top">78</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to procedure name</td>
</tr>
<tr>
<td align="center" valign="top">124</td>
<td align="center" valign="top">7C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of procedure name</td>
</tr>
<tr>
<td align="center" valign="top">128</td>
<td align="center" valign="top">80</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Statement name</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQLDA</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Procedure name</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARXP0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of statement name.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs can be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>A row that is selected but not updated is locked until the next row is
selected. Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
</table>
<br>
<p><strong>Length of procedure name.</strong> If the statement being executed
is a CALL statement, this field is the length of the procedure name. This field
will always be set to 0; it is reserved for future use.</p>
<p><strong>Length of SQLDA.</strong> The length of the SQLDA structure that
describes the host variables that are used on the statement. If zero, no host
variables were used on the statement.</p>
<p><strong>Offset to procedure name.</strong> If the statement being executed
is a CALL statement, this field is the offset from the start of the input
format structure to the procedure name as contained in the CALL statement. This
field will always be set to 0; it is reserved for future use.</p>
<p><strong>Offset to SQLDA.</strong> The offset from the start of the input
format structure to the SQLDA structure that describes the host variables that
are used on the statement. If zero, no host variables were used on the
statement.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by theARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>Procedure name.</strong> If the statement being executed is a CALL
statement, this field contains the procedure name as specified in the CALL
statement. This field will not be passed; it is reserved for future use.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>SQLDA.</strong> An SQLDA structure that describes the host variables
that are used on the statement. The SQLDA structure is described in the <a
href="#HDRSQDAFMT">SQLDA</a>.</p>
<p><strong>Statement name.</strong> The SQL statement name that is specified on
the EXECUTE statement.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>'</em></td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRXIFMT">Format ARXI0100 (Execute Immediate Statement
Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQL statement</td>
</tr>
<tr>
<td align="center" valign="top">116</td>
<td align="center" valign="top">74</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQL statement</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQL statement</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARXI0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the statement text.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs can be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>A row that is selected but not updated is locked until the next row is
selected. Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT, LABEL ON, and
REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
</table>
<br>
<p><strong>Length of SQL statement.</strong> The length of the SQL statement to
execute.</p>
<p><strong>Offset to SQL statement.</strong> The offset from the start of the
input format structure to the SQL statement to execute.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>SQL statement.</strong> The SQL statement to execute.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>'</em></td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDROCFMT">Format AROC0100 (Open Cursor Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Default collection</td>
</tr>
<tr>
<td align="center" valign="top">130</td>
<td align="center" valign="top">82</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Blocking allowed</td>
</tr>
<tr>
<td align="center" valign="top">131</td>
<td align="center" valign="top">83</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">132</td>
<td align="center" valign="top">84</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">136</td>
<td align="center" valign="top">88</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">140</td>
<td align="center" valign="top">8C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to DECLARE CURSOR</td>
</tr>
<tr>
<td align="center" valign="top">144</td>
<td align="center" valign="top">90</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of DECLARE CURSOR</td>
</tr>
<tr>
<td align="center" valign="top">148</td>
<td align="center" valign="top">94</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Cursor name</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQLDA</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">DECLARE CURSOR statement</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format AROC0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>Blocking allowed.</strong> Whether blocking should be performed for
the cursor. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">Blocking is not allowed.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Blocking is allowed.</td>
</tr>
</table>
<br>
<p><strong>CCSID.</strong> The CCSID of the statement text and cursor name.</p>
<p><strong>Cursor name.</strong> The cursor name that is specified on the OPEN
statement.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>DECLARE CURSOR statement.</strong> The DECLARE CURSOR statement as
contained in the program that is associated with the OPEN statement.</p>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs can be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>A row that is selected but not updated is locked until the next row is
selected. Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
</table>
<br>
<p><strong>Length of DECLARE CURSOR.</strong> If 1 was returned for the include
bound statements field when the ARD program was called using the ARCN0100
format, this field is the length of the associated DECLARE CURSOR statement as
contained in the program. Otherwise, this field is set to zero.</p>
<p><strong>Length of SQLDA.</strong> The length of the SQLDA structure that
describes the host variables that are used on the statement. If zero, no host
variables were used on the statement.</p>
<p><strong>Offset to DECLARE CURSOR.</strong> If 1 was returned for the include
bound statements field when the ARD program was called using the ARCN0100
format, this field is the offset of the associated DECLARE CURSOR statement as
contained in the program. Otherwise, this field is set to zero.</p>
<p><strong>Offset to SQLDA.</strong> The offset from the start of the input
format structure to the SQLDA structure that describes the host variables that
are used on the statement. If zero, no host variables were used on the
statement.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>SQLDA.</strong> An SQLDA structure that describes the host variables
that are used on the statement. The SQLDA structure is described in the <a
href="#HDRSQDAFMT">SQLDA</a>.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top">'</td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRFCFMT">Format ARFC0100 (Fetch from a Cursor Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">String delimiter</td>
</tr>
<tr>
<td align="center" valign="top">81</td>
<td align="center" valign="top">51</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Decimal delimiter</td>
</tr>
<tr>
<td align="center" valign="top">82</td>
<td align="center" valign="top">52</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Date format</td>
</tr>
<tr>
<td align="center" valign="top">92</td>
<td align="center" valign="top">5C</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Time format</td>
</tr>
<tr>
<td align="center" valign="top">102</td>
<td align="center" valign="top">66</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Isolation level</td>
</tr>
<tr>
<td align="center" valign="top">112</td>
<td align="center" valign="top">70</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Cursor name</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARFC0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the cursor name.</p>
<p><strong>Cursor name.</strong> The cursor name that is specified on the FETCH
statement.</p>
<p><strong>Date format.</strong> The format that is used when the exit program
accesses date result columns. Values passed follow (where <em>m</em>=month,
<em>d</em>=day, and <em>y</em>=year):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States date format <em>
mm/dd/yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) date
format <em>yyyy-mm-dd</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European date format <em>dd.mm.yyyy</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard date format <em>
yyyy-mm-dd</em>.</td>
</tr>
</table>
<br>
<p><strong>Decimal delimiter.</strong> The statement decimal delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>.</em></td>
<td width="95%" valign="top">The value used as the decimal point in numeric
literals is a period.</td>
</tr>
<tr>
<td valign="top"><em>,</em></td>
<td valign="top">The value used as the decimal point in numeric literals is a
comma.</td>
</tr>
</table>
<br>
<p><strong>Isolation level.</strong> The level of record locking that occurs
under commitment control. Values passed follow:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*CHG</em></td>
<td width="90%" valign="top">The following are locked until the end of the unit
of work (transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs can be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*CS</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are updated, deleted, and inserted</li>
</ul>
<p>A row that is selected but not updated is locked until the next row is
selected. Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
<tr>
<td valign="top"><em>*ALL</em></td>
<td valign="top">The following are locked until the end of the unit of work
(transaction):<br>
<ul>
<li>Objects that are referred to in SQL ALTER, COMMENT ON, CREATE, DROP, GRANT,
LABEL ON, and REVOKE statements</li>
<li>Rows that are selected, updated, deleted, and inserted</li>
</ul>
<p>Uncommitted changes in other jobs cannot be seen.</p>
</td>
</tr>
</table>
<br>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>String delimiter.</strong> The statement string delimiter for the
SQL statements. Values passed follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>'</em></td>
<td width="95%" valign="top">The character used as the string delimiter is the
apostrophe (').</td>
</tr>
<tr>
<td valign="top"><em>&quot;</em></td>
<td valign="top">The character used as the string delimiter is the quotation
mark (&quot;).</td>
</tr>
</table>
<br>
<p><strong>Time format.</strong> The format that is used when the exit program
accesses time result columns. Values passed follow (where <em>h</em>=hour, <em>
m</em>=minute, and <em>s</em>=second):</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>*USA</em></td>
<td width="90%" valign="top">The United States time format <em>hh:mm xx</em> is
used, where <em>xx</em> is A.M. or P.M.</td>
</tr>
<tr>
<td valign="top"><em>*ISO</em></td>
<td valign="top">The International Organization for Standardization (ISO) time
format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*EUR</em></td>
<td valign="top">The European time format <em>hh.mm.ss</em>.</td>
</tr>
<tr>
<td valign="top"><em>*JIS</em></td>
<td valign="top">The Japanese Industrial Standard time format <em>
hh:mm:ss</em>.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRCCFMT">Format ARCC0100 (Close a Cursor Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Cursor name</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARCC0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the cursor name.</p>
<p><strong>Cursor name.</strong> The cursor name specified on the CLOSE
statement.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<br>
<h3><a name="HDRDSFMT">Format ARDS0100 (Describe a Statement Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package collection</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Package name</td>
</tr>
<tr>
<td align="center" valign="top">62</td>
<td align="center" valign="top">3E</td>
<td align="left" valign="top">CHAR(8)</td>
<td align="left" valign="top">Package consistency token</td>
</tr>
<tr>
<td align="center" valign="top">70</td>
<td align="center" valign="top">46</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">72</td>
<td align="center" valign="top">48</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Section number</td>
</tr>
<tr>
<td align="center" valign="top">76</td>
<td align="center" valign="top">4C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">80</td>
<td align="center" valign="top">50</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">Statement name</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARDS0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the statement name.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>Package collection.</strong> The collection for the package that the
statement is associated with. A collection is a name that provides a logical
grouping for SQL objects.</p>
<p><strong>Package consistency token.</strong> The consistency token for the
package that the statement is associated with. Refer to <a href="#HDRCONTKN">
Consistency Token</a> for a description of this field.</p>
<p><strong>Package name.</strong> The name of the package that the statement is
associated with.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Section number.</strong> The section number that the statement is
associated with. Refer to <a href="#HDRSECNUM">Section Number</a> for more
information on section numbers.</p>
<p><strong>Statement name.</strong> The statement name that is specified on the
DESCRIBE statement.</p>
<br>
<h3><a name="HDRDTFMT">Format ARDT0100 (Describe Object Format)</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Output format buffer size</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Activation group number</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(18)</td>
<td align="left" valign="top">RDB name</td>
</tr>
<tr>
<td align="center" valign="top">26</td>
<td align="center" valign="top">1A</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">28</td>
<td align="center" valign="top">1C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">CCSID</td>
</tr>
<tr>
<td align="center" valign="top">32</td>
<td align="center" valign="top">20</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to object name</td>
</tr>
<tr>
<td align="center" valign="top">36</td>
<td align="center" valign="top">24</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of object name</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Object name</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Format ARDT0100</h3>
<p><strong>Activation group number.</strong> The activation group number of the
program that is performing the request. See <a href="#HDRACTGRP">Activation
Group</a> for a description of what an activation group is.</p>
<p><strong>CCSID.</strong> The CCSID of the object name.</p>
<p><strong>Length of object name.</strong> The length of the name of the SQL
object to describe.</p>
<p><strong>Object name.</strong> The name of the SQL object to be described.
This may be either a qualified or unqualified table name. If it is qualified,
it will be in the SQL naming format, that is, a collection name followed by a
period and an SQL identifier.</p>
<p><strong>Offset to object name.</strong> The offset from the start of the
input format structure to the name of the SQL object to describe.</p>
<p><strong>Output format buffer size.</strong> The amount of storage allocated
for the output format that is returned by the ARD program. The length of the
output format must be less than or equal to this value. It must also conform to
the description of the output format associated with this input format. See the
description of the <a href="#SPTOUTFMT">output format parameter</a> on for a
description of the output format associated with this input format.</p>
<p><strong>RDB name.</strong> The name of the relational database that the
request was directed to.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<br>
<h3>Output Format Structures</h3>
<p>In the following structures, the CCSID of the character fields is the job
CCSID unless a specific CCSID field is included in the format for the
field.</p>
<br>
<h3><a name="HDROCNFMT">Output Connect Format</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">CHAR(3)</td>
<td align="left" valign="top" width="60%">Server product</td>
</tr>
<tr>
<td align="center" valign="top">3</td>
<td align="center" valign="top">3</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Server version</td>
</tr>
<tr>
<td align="center" valign="top">5</td>
<td align="center" valign="top">5</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Server release</td>
</tr>
<tr>
<td align="center" valign="top">7</td>
<td align="center" valign="top">7</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Server level</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">User ID</td>
</tr>
<tr>
<td align="center" valign="top">18</td>
<td align="center" valign="top">12</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Include bound statements</td>
</tr>
<tr>
<td align="center" valign="top">19</td>
<td align="center" valign="top">13</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Protected conversation</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Output Connect Format</h3>
<p><strong>Include bound statements.</strong> Whether statements that were sent
at package-creation time should be included in run-time formats ARXD0100,
ARXB0100, and AROC0100. Valid values follow:</p>
<table width="100%">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">Do not include bound statements.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Include bound statements.</td>
</tr>
</table>
<br>
<p><strong>Protected conversation.</strong> Whether a protected conversation is
used for the connection. If the connection uses a protected conversation, the
system rejects attempts by the application to run the DISCONNECT SQL statement.
Connections that use protected conversations are only ended during commit and
rollback processing. See the description of the disconnect type field (page <a
href="#SPTDISCT">Disconnect type</a>) for format ARDI0100 for more information.
Valid values follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">Conversation is not protected.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Conversation is protected.</td>
</tr>
</table>
<br>
<p><strong>Server level.</strong> An identifier for the level of the database
server that is accessed by the ARD program. This value must be a character
representation of a hexadecimal value. That is, it may only consist of the
characters 0-9 and A-F.</p>
<p><strong>Server product.</strong> An identifier for the database server that
is accessed by the ARD program. The system does no verification of the value of
this field.</p>
<p><strong>Server release.</strong> An identifier for the release of the
database server that is accessed by the ARD program. This value must be a
character representation of a hexadecimal value. That is, it may only consist
of the characters 0-9 and A-F.</p>
<p><strong>Server version.</strong> An identifier for the version of the
database server that is accessed by the ARD program. This value must be a
character representation of a hexadecimal value. That is, it may only consist
of the characters 0-9 and A-F. The system does no verification of the value of
this field.</p>
<p><strong>User ID.</strong> The user ID that is used at the server.</p>
<br>
<h3><a name="HDROXDFMT">Output Execute Format</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">CHAR(1)</td>
<td align="left" valign="top" width="60%">Update performed</td>
</tr>
<tr>
<td align="center" valign="top">1</td>
<td align="center" valign="top">1</td>
<td align="left" valign="top">CHAR(3)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQLDA</td>
</tr>
<tr>
<td align="center" valign="top">8</td>
<td align="center" valign="top">8</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to result set</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQLDA</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Result set</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Output Execute Format</h3>
<p><strong>Offset to result set.</strong> The offset from the start of the
output format to the result set. If the SQLCA indicates an error occurred, this
field must be set to 0.</p>
<p><strong>Offset to SQLDA.</strong> An offset from the start of the output
format to the SQLDA structure that describes the columns for the results of the
statement. This field can only have a value of 0 or a multiple of 16. If the
SQLCA indicates an error occurred, this field must be set to 0. If the SQLCA
does not indicate an error, this field cannot be 0.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>Result set.</strong> The result for the SQL statement. Columns are
contiguous with null indicators (if appropriate) that precede the column data.
Refer to <a href="#HDRDATAFMT">Query (Fetch) Data Format</a> for more
information. If the offset to result set field is 0, this field must not be
included in the output format.</p>
<p><strong>Note:</strong> This null indicator is not the same as the NULL in
the C language.</p>
<p><strong>SQLDA.</strong> An SQLDA structure that describes the columns for
the results of the statement. The SQLDA structure is described in <a href=
"#HDRSQDAFMT">SQLDA</a>. If the offset to SQLDA field is 0, this field must not
be included in the output format.</p>
<p><strong>Update performed.</strong> Whether the statement resulted in an
update. An update is any operation that results in a change to an object such
that the object is under commitment control. Valid values follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">The operation did not result in an update.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">An update occurred from the operation.</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDROOCFMT">Output Open Cursor Format</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">CHAR(1)</td>
<td align="left" valign="top" width="60%">Block data</td>
</tr>
<tr>
<td align="center" valign="top">1</td>
<td align="center" valign="top">1</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Cursor held</td>
</tr>
<tr>
<td align="center" valign="top">1</td>
<td align="center" valign="top">1</td>
<td align="left" valign="top">CHAR(2)</td>
<td align="left" valign="top">Reserved</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Offset to SQLDA</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">SQLDA</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Output Open Cursor Format</h3>
<p><strong>Block data.</strong> Whether the ARD program will block the data.
Valid values follow:</p>
<table width="100%">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">A single row of data will be returned.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Data will be returned in blocks.</td>
</tr>
</table>
<br>
<p><strong>Cursor held.</strong> Whether the cursor is held open after commits.
Valid values follow:</p>
<table width="100%">
<tr>
<td width="5%" valign="top"><em>0</em></td>
<td width="95%" valign="top">Cursor is closed after commits.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">Cursor is held open after commits.</td>
</tr>
</table>
<br>
<p><strong>Offset to SQLDA.</strong> The offset from the start of the output
format to the SQLDA structure that describes the columns for the results of the
statement. This field can only have a value of 0 or a multiple of 16. If the
SQLCA indicates that an error occurred, this field must be set to 0. If the
SQLCA does not indicate an error, this field cannot be 0.</p>
<p><strong>Reserved.</strong> An ignored field.</p>
<p><strong>SQLDA.</strong> An SQLDA structure that describes the columns for
the results of the statement. The SQLDA structure is described in <a href=
"#HDRSQDAFMT">SQLDA</a>. If the offset to SQLDA field is 0, this field must not
be included in the output format.</p>
<br>
<h3><a name="HDROFCFMT">Output Fetch Cursor Format</a></h3>
<table border width="80%">
<tr>
<th align="center" valign="bottom" colspan="2">Offset</th>
<th align="left" valign="bottom" rowspan="2">Type</th>
<th align="left" valign="bottom" rowspan="2">Field</th>
</tr>
<tr>
<th align="center" valign="bottom">Dec</th>
<th align="center" valign="bottom">Hex</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0</td>
<td align="center" valign="top" width="10%">0</td>
<td align="left" valign="top" width="20%">BINARY(4)</td>
<td align="left" valign="top" width="60%">Offset to result set</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="center" valign="top">4</td>
<td align="left" valign="top">CHAR(1)</td>
<td align="left" valign="top">Cursor closed</td>
</tr>
<tr>
<td align="center" valign="top"></td>
<td align="center" valign="top"></td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Result set</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions for Output Fetch Cursor Format</h3>
<p><strong>Cursor closed.</strong> Whether the cursor is closed. Valid values
follow:</p>
<table width="100%">
<!-- cols="5 95" -->
<tr>
<td valign="top"><em>0</em></td>
<td valign="top">The cursor is open.</td>
</tr>
<tr>
<td valign="top"><em>1</em></td>
<td valign="top">The cursor is closed.</td>
</tr>
</table>
<br>
<p><strong>Offset to result set.</strong> The offset from the start of the
output format to the result set. If no data is returned, this field should be
set to 0.</p>
<p><strong>Result set.</strong> The result for the SQL statement. Columns are
contiguous with null indicators (if appropriate) that precede the column data.
Refer to <a href="#HDRDATAFMT">Query (Fetch) Data Format</a> for more
information. If the offset to result set field is 0, this field must not be
included in the output format.</p>
<p><strong>Note:</strong> This null indicator is not the same as the NULL in
the C language.</p>
<br>
<h3><a name="HDRACTGRP">Activation Group</a></h3>
<p>An activation group provides the following:</p>
<ul>
<li>Run-time data structures to support the running of programs</li>
<li>Addressing protection</li>
<li>A logical boundary for message creation</li>
<li>A logical boundary for application cleanup processing</li>
</ul>
<p>Connections are scoped to the activation group. Therefore, the activation
group mark and the RDB name together are used to uniquely identify the
connection. It is not possible to have more than one connection active with the
same RDB name in the same activation group at a point in time. However, it is
possible to have multiple connections with different RDB names in the same
activation group and to have multiple connections with the same RDB name in
different activation groups.</p>
<br>
<h3><a name="HDRCONTKN">Consistency Token</a></h3>
<p>The system associates a consistency token with every program. If a program
is compiled again, a new consistency token is created. When a user or
application creates a package with the CRTSQLxxx commands or the CRTSQLPKG
command and an RDB that is associated with an ARD program is specified on the
command, the package consistency token from the program along with a package
name and package collection is passed to the ARD program. In addition, at
program run time, the ARD program will be passed the package name, package
collection, and package consistency token that are currently associated with
the program.</p>
<p>The ARD program can use this information passed to it during run time to
verify that information passed to it during package creation is correct for the
instance of the program being run. If a package does not exist for the given
package consistency token, package name, and package collection, the exit
program should return messages SQLCODE (-805) and SQLSTATE (51002).</p>
<br>
<h3><a name="HDRSECNUM">Section Number</a></h3>
<p>When a user or application creates a package with the CRTSQLxxx commands or
the CRTSQLPKG command and an RDB that is associated with an ARD program is
specified on the command, statements contained in the program are passed to the
ARD program. A section number is associated with the statements. A section
number is a signed binary number ranging from 1 to 32767. Section numbers may
not necessarily be consecutive.</p>
<p>Related statements share the same section numbers. Therefore, a cursor
declared for a statement and each statement that references the declared
statement or cursor (FETCH, EXECUTE, OPEN, CLOSE, PREPARE) have the same
section number. However, each uniquely declared statement or cursor has a
different section number.</p>
<p>The system assigns a unique section number to the following statements and
any other statements that it does not understand:</p>
<ul>
<li>ALTER</li>
<li>COMMENT ON</li>
<li>CREATE</li>
<li>DELETE</li>
<li>DROP</li>
<li>EXPLAIN</li>
<li>GRANT</li>
<li>INSERT</li>
<li>LABEL ON</li>
<li>LOCK</li>
<li>REVOKE</li>
<li>SELECT (embedded)</li>
<li>SET</li>
<li>UPDATE</li>
<li>EXECUTE IMMEDIATE</li>
<li>CALL</li>
<li>DECLARE PROCEDURE</li>
</ul>
<p>The following statements are not passed to the ARD program during the
package creation process. Also, local statements that are understood by the
precompiler but do not result in calls to the ARD program at run time are not
passed.</p>
<ul>
<li>INCLUDE</li>
<li>WHENEVER</li>
<li>PREPARE</li>
<li>EXECUTE</li>
<li>EXECUTE IMMEDIATE</li>
<li>DESCRIBE</li>
<li>OPEN</li>
<li>FETCH</li>
<li>CLOSE</li>
<li>COMMIT</li>
<li>CONNECT</li>
<li>ROLLBACK</li>
<li>RELEASE</li>
<li>SET CONNECTION</li>
<li>DISCONNECT</li>
<li>BEGIN DECLARE SECTION</li>
<li>END DECLARE SECTION</li>
</ul>
<br>
<h3><a name="HDRDATAFMT">Query (Fetch) Data Format</a></h3>
<p>Query data is returned as a continuous collection of columns. Multiple rows
of data may also be returned for format ARFC0100 when the ARD program returned
1 for the block data field on format AROC0100. When multiple rows of data are
returned, the rows are also contiguous.</p>
<p>If a column is a null-capable or a derived field (for example COL1/COL2),
the column data is preceded with a 1-byte null indicator. The length of data
returned for variable-length data types should be based on the length in the
length indicator. It should not be padded to the length of the field.
Representation of all data types is assumed to be in the format used by
i5/OS.</p>
<p>The null indicator is a 1-byte signed binary integer. If the null indicator
is negative (between X'80' and X'FF', inclusive), no column data should follow
the indicator. For data conversion errors, -2 (X'FE') should be used for the
null indicator.</p>
<p>If a data conversion error occurs and the column is non-null-capable, an
error sqlcode should be returned in the SQLCA. When an error (negative SQLCODE)
is indicated in the SQLCA and the ARD program is not returning multiple rows,
no data should be returned. When multiple rows of data are being returned for a
query and the ARD program returns an error in the SQLCA, the row that the error
applies to should not be included in the block and the row previous to the row
in error should be the last row returned.</p>
<p>When a warning (positive SQLCODE) is indicated in the SQLCA and the ARD
program is not returning multiple rows, the row should be returned. When
multiple rows of data are being returned for a query and an ARD program returns
a warning in the SQLCA, the row that the warning applies to should be the last
row in the block.</p>
<p>If the ARD program has not indicated that the cursor is closed in the cursor
closed field of the output format for ARFC0100, the system will call the ARD
program to get additional rows when the application requests a row after the
row that the warning or error applies to. If the ARD program indicated the
cursor was closed, the system will not call the ARD program for that cursor
again until the application performs another SQL OPEN.</p>
<p>The following illustration shows an example of two rows of data being
returned for a FETCH. The two rows each consist of a null-capable smallint
COL1, a non-null-capable CHAR(3) COL2, a null-capable smallint COL3, and a
non-null-capable VARCHAR(20) COL4.</p>
<pre>
Hex Representation Description
00 Row 1 - Null byte for COL1 - not null
0001 Row 1 - COL1 (smallint) value = 1
D1E6E3 Row 1 - COL2 (CHAR(3)) value = JWT
FF Row 1 - Null byte for COL3 - null
0007D1C5C6C6D9C5E8 Row 1 - COL4 Length = 7 value = JEFFREY
FF Row 2 - Null byte for COL1 - null
D1D4C2 Row 2 - COL2 (CHAR(3)) value = JMB
00 Row 2 - Null byte for COL3 - not null
0002 Row 2 - COL3 (smallint) value = 2
0004D1D6C8D5 Row 1 - COL4 Length = 4 value = JOHN
</pre>
<br>
<p>In response to format ARXD0100 when data is returned for a CALL statement, a
null indicator must precede each field regardless of whether the field is
null-capable or not. For any parameters declared as input-only on the DECLARE
PROCEDURE statement, the null indicator must be set to X'80'.</p>
<p>The following illustration shows an example of the data returned for a CALL
where the first parameter was an input-only parameter and the second was an
output smallint.</p>
<pre>
Hex Representation Description
80 Parm 1 - Null byte - input only
00 Parm 2 - Null byte - not null
0001 Parm 2 - Value = 1
</pre>
<br>
<h3><a name="HDRSQDAFMT">SQLDA</a></h3>
<p>An SQLDA is a set of variables that describe either host variables or column
attributes. Included in this topic are the SQLDA structure, the relevant
settings for those fields that the ARD program returns to the operating system,
and the relevant fields that are passed to the ARD program.</p>
<p>For more information about SQLDA, see SQL Descriptor Area (SQLDA) in the <a
href="../db2/rbafzmst02.htm">DB2 UDB for iSeries SQL Reference</a> topic.</p>
<p>The SQLDA has the following fields (shown in C-language format):</p>
<pre>
struct sqlda
{
unsigned char sqldaid[8];
long sqldabc;
short sqln;
short sqld;
struct sqlvar
{
short sqltype;
short sqllen;
unsigned char sqlres[12];
unsigned char *sqldata;
short *sqlind;
struct sqlname
{
short length;
unsigned char data[30];
} sqlname;
} sqlvar[1];
};
</pre>
<br>
<p>In response to the ARPD0100, ARDS0100, and ARDT0100 formats, the following
fields must be set on the return from the ARD program:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqldaid</em></td>
<td width="90%" valign="top">An eye-catcher for diagnostic purposes. This must
be set to 'SQLDA'.</td>
</tr>
<tr>
<td valign="top"><em>sqldabc</em></td>
<td valign="top">The length of the SQLDA. Its value is calculated as
'2*sqld*sizeof(sqlvar) + 16'.</td>
</tr>
<tr>
<td valign="top"><em>sqld</em></td>
<td valign="top">A number equal to the number of columns described. The actual
number of sqlvar occurrences returned should be twice this number. If the
statement being described is not a SELECT statement, this field is set to
0.</td>
</tr>
<tr>
<td valign="top"><em>sqlvar</em></td>
<td valign="top">A structure that contains two entries for each column in the
result table. If <em>n</em>is the number of columns being described, the first
<em>n</em> sqlvar entries contain the following:
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqltype</em></td>
<td width="90%" valign="top">The sqltype of the column in the select list of
the result table. See the <a href="../db2/rbafzmst02.htm">DB2 UDB for iSeries
SQL Reference</a> topic for a complete list of field data types and their
corresponding sqltype value.</td>
</tr>
<tr>
<td valign="top"><em>sqllen</em></td>
<td valign="top">The length attribute of the column.</td>
</tr>
<tr>
<td valign="top"><em>sqldata</em></td>
<td valign="top">For character data, the CCSID of the field in the following
format: bytes 1 and 2 are set to X'00' and bytes 3 and 4 are set to the CCSID
value.</td>
</tr>
<tr>
<td valign="top"><em>sqlind</em></td>
<td valign="top">Reserved. This must be set to X'00'.</td>
</tr>
<tr>
<td valign="top"><em>sqlname</em></td>
<td valign="top">The unqualified name of the column.
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqlname.length</em></td>
<td width="90%" valign="top">The length of the unqualified name of the
column.</td>
</tr>
<tr>
<td valign="top"><em>sqlname.data</em></td>
<td valign="top">The unqualified column name. The CCSID of the value is the
CCSID of the job.</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<p>And the second <em>n</em> entries contain the following:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqltype</em></td>
<td width="90%" valign="top">Reserved. This must be set to X'00'.</td>
</tr>
<tr>
<td valign="top"><em>sqllen</em></td>
<td valign="top">Reserved. This must be set to X'00'.</td>
</tr>
<tr>
<td valign="top"><em>sqldata</em></td>
<td valign="top">Reserved. This must be set to X'00'.</td>
</tr>
<tr>
<td valign="top"><em>sqlind</em></td>
<td valign="top">Reserved. This must be set to X'00'.</td>
</tr>
<tr>
<td valign="top"><em>sqlname</em></td>
<td valign="top">The label of the column.
<table width="100%">
<tr>
<td width="15%" valign="top"><em>sqlname.length</em></td>
<td width="85%" valign="top">The length of the column label.</td>
</tr>
<tr>
<td valign="top"><em>sqlname.data</em></td>
<td valign="top">The column label. The CCSID of the value is the CCSID of the
job.</td>
</tr>
</table>
</td>
</tr>
</table>
<p>In response to formats AROC0100 and ARXD0100, the following fields must be
set on the return from the ARD program:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqldaid</em></td>
<td width="90%" valign="top">An eye-catcher for diagnostic purposes. This must
be set to 'SQLDA'.</td>
</tr>
<tr>
<td valign="top"><em>sqldabc</em></td>
<td valign="top">The length of the SQLDA. Its value is calculated as
'sqld*sizeof(sqlvar) + 16'.</td>
</tr>
<tr>
<td valign="top"><em>sqld</em></td>
<td valign="top">The number of columns in the result table.</td>
</tr>
<tr>
<td valign="top"><em>sqlvar</em></td>
<td valign="top">A structure that contains an entry for each column in the
result table. The entries contain the following fields:
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqltype</em></td>
<td width="90%" valign="top">The sqltype of the column in the select list of
the result table. See the <a href="../db2/rbafzmst02.htm">DB2 UDB for iSeries
SQL Reference</a> topic for a complete list of field data types and their
corresponding sqltype value.</td>
</tr>
<tr>
<td valign="top"><em>sqllen</em></td>
<td valign="top">The length attribute of the column.</td>
</tr>
<tr>
<td valign="top"><em>sqldata</em></td>
<td valign="top">For character data, the CCSID of the field in the following
format: bytes 1 and 2 are set to X'00' and bytes 3 and 4 are set to the CCSID
value.</td>
</tr>
<tr>
<td valign="top"><em>sqlind</em></td>
<td valign="top">Reserved. This must be set to X'00'.</td>
</tr>
<tr>
<td valign="top"><em>sqlname</em></td>
<td valign="top">The unqualified name of the column.<br>
<table width="100%">
<tr>
<td width="15%" valign="top"><em>sqlname.length</em></td>
<td width="85%" valign="top">The length of the unqualified name of the
column.</td>
</tr>
<tr>
<td valign="top"><em>sqlname.data</em></td>
<td valign="top">The unqualified column name. The CCSID of the value is the
CCSID of the job.</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<br>
<p>On input to the ARD program on formats ARBS0100, ARXD0100, ARXB0100,
ARXP0100, and AROC0100, the ARD program must interpret the SQLDA because it
describes host variables to be used with the statement. The relevant fields
are:</p>
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqld</em></td>
<td width="90%" valign="top">The number of host variables for the
statement.</td>
</tr>
<tr>
<td valign="top"><em>sqlvar</em></td>
<td valign="top">A structure that contains one entry for each host variable.
The entries contain the following:
<table width="100%">
<tr>
<td width="10%" valign="top"><em>sqltype</em></td>
<td width="90%" valign="top">The sqltype of the host variable. See the <a href=
"../db2/rbafzmst02.htm">DB2 UDB for iSeries SQL Reference</a> topic for a
complete list of field data types and their corresponding sqltype value. An odd
value for sqltype indicates that this sqlvar entry contains a pointer to an
indicator variable that is addressed by sqlind.</td>
</tr>
<tr>
<td valign="top"><em>sqllen</em></td>
<td valign="top">The length attribute of the host variable.</td>
</tr>
<tr>
<td valign="top"><em>sqldata</em></td>
<td valign="top">A pointer to the host variable data. This field is set to NULL
for format ARBS0100.</td>
</tr>
<tr>
<td valign="top"><em>sqlind</em></td>
<td valign="top">A pointer to an indicator variable. The indicator variable is
a 2-byte binary value that signifies a NULL value when sqlind is set to a
negative value. This field is only relevant if the sqltype field is odd. This
field is set to NULL for format ARBS0100.</td>
</tr>
<tr>
<td valign="top"><em>sqlname</em></td>
<td valign="top">The coded character set identifier (CCSID) for character host
variables.<br>
<table width="100%">
<tr>
<td width="15%" valign="top"><em>sqlname.data</em></td>
<td width="85%" valign="top">The CCSID of the field in the following format:
bytes 1 and 2 are set to X'00' and bytes 3 and 4 are set to the CCSID
value.</td>
</tr>
<tr>
<td valign="top"><em>sqlname.length</em></td>
<td valign="top">This field is set to 8.</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
<br>
<br>
<h3><a name="HDRCMTAPI">Commit APIs</a></h3>
<p>To process commit and rollback requests, providers of ARD programs must
register a commitment control resource. Refer to <a href="#HDRCMTAPI">Commit
APIs</a> for more information on the commitment control APIs. The following
section assumes an understanding of the commit APIs.</p>
<p>The Add Commitment Resource (QTNADDCR) API should be called to add a
commitment resource to a commitment definition. After the resource is added,
the exit program specified on the Add Commitment Resource API is called during
commitment control operations for the commitment definition. When registering
commitment resources for use with ARD programs, the commitment resource should
be added after the first successful operation after the ARCN0100 format call.
It is best not to perform this operation as part of the ARCN0100 format call
since once a commitment control API resource is registered, the commitment
definition is no longer at a logical unit-of-work boundary. A CONNECT operation
does not normally change the logical unit-of-work boundary of a commitment
definition. If a commitment resource is registered during the ARCN0100 format
call, the create SQL package (CRTSQLPKG) function fails.</p>
<p>The Remove Commitment Resource (QTNRMVCR) API should be called to remove a
resource from a commitment definition. This API should be called after
processing the ARDI0100 format call. It cannot be called during the ARDI0100
format call if the ARDI0100 format indicates that the disconnection is
occurring as part of a commit or rollback. A disconnect type of 3 indicates
that the disconnect is occurring as part of a commit or rollback. In this
situation, the commit resource should be removed either during the next SQL
operation the ARD program processes or during the next commit or rollback
operation. In the latter case, the commitment control exit program can have the
resource removed by using the changes ended field in the return information
format. Until this resource is removed, the Create SQL Package (CRTSQLPKG)
command will fail.</p>
<hr>
Exit program introduced: V3R6
<hr>
<center>
<table cellpadding="2" cellspacing="2">
<tr align="center">
<td valign="middle" align="center"><a href="#top_Of_Page">Top</a> | <a href=
"file1.htm">Database and File APIs</a> | <a href="aplist.htm">APIs by
category</a></td>
</tr>
</table>
</center>
</body>
</html>