ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzaik_5.4.0.1/rzaikodbcexitprog.htm

85 lines
4.8 KiB
HTML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="reference" />
<meta name="DC.Title" content="Exit programs" />
<meta name="abstract" content="An exit program is a program to which control is passed from a calling program." />
<meta name="description" content="An exit program is a program to which control is passed from a calling program." />
<meta name="DC.Relation" scheme="URI" content="rzaikodbcperfconsd.htm" />
<meta name="DC.Relation" scheme="URI" content="rzaiksampluserextpgm.htm" />
<meta name="DC.Relation" scheme="URI" content="rzaikexitpgmparmformat.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1999, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1999, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="odbcexitprog" />
<meta name="DC.Language" content="en-us" />
<!-- 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. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Exit programs</title>
</head>
<body id="odbcexitprog"><a name="odbcexitprog"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Exit programs</h1>
<div><p>An exit program is a program to which control is passed from a
calling program.</p>
<div class="section"><p>When you specify an <strong>exit program</strong>, the servers pass the
following two parameters to the exit program before running your request: </p>
<ul><li>A 1-byte return code value.</li>
<li>A structure containing information about your request. This structure
is different for each of the exit points.</li>
</ul>
</div>
<div class="section"><p>These two parameters allow the exit program to determine whether
your request is allowed. If the exit program sets the return code to <span>X'F0'</span>,
the server rejects the request. If the return code is set to anything else,
the server allows the request.</p>
</div>
<div class="section"><p>The same program can be used for multiple exit points. The program
can determine what function is being called by looking at the data in the
second parameter structure.</p>
</div>
<div class="section"><p>Use the <span class="cmdname">Work with Registration Information (WRKREGINF)</span> command
to add your exit programs to the database exit points.</p>
</div>
<div class="section"><p>The database server has five different exit points defined: </p>
<dl><dt class="dlterm">QIBM_QZDA_INIT</dt>
<dd>called at server initiation</dd>
<dt class="dlterm">QIBM_QZDA_NDB1</dt>
<dd>called for native database requests</dd>
<dt class="dlterm">QIBM_QZDA_SQL1</dt>
<dd>called for SQL requests</dd>
<dt class="dlterm">QIBM_QZDA_SQL2</dt>
<dd>called for SQL requests</dd>
<dt class="dlterm">QIBM_QZDA_ROI1</dt>
<dd>called for retrieving object information requests and SQL catalog functions <div class="note"><span class="notetitle">Note:</span> This
exit point is called less often than in V5R1 and earlier Client Access ODBC
drivers. If you have an exit program that uses this exit point, verify that
it still works as intended.</div>
</dd>
</dl>
</div>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="rzaiksampluserextpgm.htm">Examples: User exit programs</a></strong><br />
The following examples do not show all of the programming considerations or techniques. Review the examples before you begin application design and coding.</li>
<li class="ulchildlink"><strong><a href="rzaikexitpgmparmformat.htm">Exit program parameter formats</a></strong><br />
The exit points for native database and retrieving object information have two formats that are defined: QIBM_QZDA_SQL1 and QIBM_QZDA_SQL2. Depending on the type of function that is requested, one of the formats is used.</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="rzaikodbcperfconsd.htm" title="See any of the following ODBC performance topics.">iSeries Access for Windows ODBC performance</a></div>
</div>
</div>
</body>
</html>