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

464 lines
13 KiB
HTML
Raw Normal View History

2024-04-02 14:02:31 +00:00
<!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>Retrieve Clustered Hash Table Entry (QcstRetrieveCHTEntry) API</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. -->
<!-- Change History: -->
<!-- YYMMDD USERID Change description -->
<!-- qctRetrieveElement.htm created by Vicki Morey on Wed Dec 6 2000 -->
<!-- Edited by Kersten Oct 2001 -->
<!-- End Header Records -->
<!-- -->
<!-- -->
<!-- -->
<!-- Begin Developer Note ========================================== -->
<!-- NOTE: If you are adding, changing, or removing ANY requirements -->
<!-- for this API chance are good that the GUI code need to change -->
<!-- also. The Cluster GUI code is built on top of this API and it -->
<!-- does a certain amount of explicit and implicit validation -->
<!-- checking of user data prior to the API call being made. Please -->
<!-- have the Cluster GUI developer check the -->
<!--/as400/v5r4m0.guix/cur/cmvc/java.pgm/ugcl.guix/com/ibm/as400/opnav/ugcl/ClGuiActionsManager.java/ClGuiActionsManager.java -->
<!-- part to determine if any Cluster GUI code changes are needed. -->
<!-- End Developer Note -->
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
</head>
<body>
<!--Java sync-link-->
<script type="text/javascript" language="Javascript" src="../rzahg/synch.js">
</script>
<a name="Top_Of_Page"></a>
<h2>Retrieve Clustered Hash Table Entry (QcstRetrieveCHTEntry) API</h2>
<div class="box" style="width: 70%;">
<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%">Receiver variable</td>
<td align="LEFT" valign="TOP" width="20%">Output</td>
<td align="LEFT" valign="TOP" width="20%">Void(*)</td>
</tr>
<tr>
<td align="center" valign="TOP">2</td>
<td align="LEFT" valign="TOP">Length of receiver variable</td>
<td align="LEFT" valign="TOP">Input</td>
<td align="LEFT" valign="TOP">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="TOP">3</td>
<td align="LEFT" valign="TOP">Connection handle</td>
<td align="LEFT" valign="TOP">Input</td>
<td align="LEFT" valign="TOP">Char(16)</td>
</tr>
<tr>
<td align="center" valign="TOP">4</td>
<td align="LEFT" valign="TOP">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">Length of key</td>
<td align="LEFT" valign="TOP">Input</td>
<td align="LEFT" valign="TOP">Binary(4)</td>
</tr>
<tr>
<td align="center" valign="TOP">6</td>
<td align="LEFT" valign="TOP">Key</td>
<td align="LEFT" valign="TOP">Input</td>
<td align="LEFT" valign="TOP">Char(*)</td>
</tr>
<tr>
<td align="center" valign="TOP">7</td>
<td align="LEFT" valign="TOP">Error code</td>
<td align="LEFT" valign="TOP">I/O</td>
<td align="LEFT" valign="TOP">Void(*)</td>
</tr>
</table>
<br>
&nbsp;&nbsp;Service Program: QCSTCHT<br>
<!-- iddvc RMBR -->
<br>
&nbsp;&nbsp;Default Public Authority: *USE<br>
<!-- iddvc RMBR -->
<br>
&nbsp;&nbsp;Threadsafe: Yes<br>
<!-- iddvc RMBR -->
<br>
</div>
<p>The Retrieve Clustered Hash Table Entry (QcstRetrieveCHTEntry) API retrieves
an entry from the clustered hash table specified by the connection handle
parameter. The entry to be retrieved is identified by the key parameter. If the
entry exists, is not expired and the requesting user is authorized, the
information will be returned in the receiver parameter in the selected
format.<br>
</p>
<h3>Restrictions:</h3>
<ul>
<li>A connection must have been established with the clustered hash table
server.</li>
<li>When this API is called, the clustered hash table server must be active on
the requesting node.</li>
<li>This API must be run under the same job that issued the <a href=
"clchtconnect.htm">Connect Clustered Hash Table</a> (QcstConnectCHT) API.</li>
</ul>
<br>
<h3>Authorities and Locks</h3>
<dl>
<dt><em>Entry Authority Access Level (for restricted entries)</em></dt>
<dd>*ALLOBJ or owner of the entry</dd>
</dl>
<br>
<h3>Required Parameter Group</h3>
<dl>
<dt><strong>Receiver variable</strong></dt>
<dd>OUTPUT; CHAR(*)
<p>The receiver variable that receives the information requested. You can
specify the size of the area to be smaller than the format requested as long as
you specify the length of the parameter correctly. As a result, the API returns
only the information that the area can hold.</p>
</dd>
<dt><strong>Length of receiver variable</strong></dt>
<dd>INPUT; BINARY(4)
<p>The length of the receiver variable provided. The length of receiver
variable parameter may be specified up to the size of the receiver variable
specified in the user program. If the length of the receiver variable parameter
specified is larger than the allocated size of the receiver variable specified
in the user program, the results are not predictable. The minimum length is 8
bytes.</p>
</dd>
<dt><strong>Connection handle</strong></dt>
<dd>INPUT; CHAR(16)
<p>This is an active connection handle for the clustered hash table server. It
is obtained by calling the <a href="clchtconnect.htm">Connect Clustered Hash
Table</a> (QcstConnectCHT) API.</p>
</dd>
<dt><strong>Format name</strong></dt>
<dd>INPUT; CHAR(8)
<p>The content and format of the information that is returned. The possible
format names are as follows:</p>
<table cellpadding="5">
<!-- cols="25 75" -->
<tr>
<td align="left" valign="top"><em>CHTR0100</em></td>
<td align="left" valign="top">Entry information. For more information, see <a href="#chtr0100">CHTR0100
Format</a>.</td>
</tr></table>
<br>
</dd>
<dt><strong>Length of key</strong></dt>
<dd>INPUT; BINARY(4)
<p>The length of the key of the entry to be retrieved. This must be
16 bytes.</p>
</dd>
<dt><strong>Key</strong></dt>
<dd>INPUT; Char(*)
<p>The key of the entry to be retrieved.</p>
</dd>
<dt><strong>Error code</strong></dt>
<dd>I/O; CHAR(*)
<p>The structure in which to return error information. For the format of the
structure, see <a href="../apiref/error.htm#hdrerrcod">Error code parameter</a>.</p>
</dd>
</dl>
<br>
<h3><a name="chtr0100">CHTR0100 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%">Bytes returned</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">Bytes available</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 data</td>
</tr>
<tr>
<td align="center" valign="top">12</td>
<td align="center" valign="top">C</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Length of data</td>
</tr>
<tr>
<td align="center" valign="top">16</td>
<td align="center" valign="top">10</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Entry status</td>
</tr>
<tr>
<td align="center" valign="top">20</td>
<td align="center" valign="top">14</td>
<td align="left" valign="top">BINARY(4)</td>
<td align="left" valign="top">Authority access level</td>
</tr>
<tr>
<td align="center" valign="top">24</td>
<td align="center" valign="top">18</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Owning user profile</td>
</tr>
<tr>
<td align="center" valign="top">34</td>
<td align="center" valign="top">22</td>
<td align="left" valign="top">CHAR(10)</td>
<td align="left" valign="top">Storing user profile</td>
</tr>
<tr>
<td align="center" valign="top">44</td>
<td align="center" valign="top">2C</td>
<td align="left" valign="top">CHAR(*)</td>
<td align="left" valign="top">Data</td>
</tr>
</table>
<br>
<br>
<h3>Field Descriptions</h3>
<p><strong>Authority access level.</strong> This field describes who is allowed
to retrieve and update the entry. Valid special values are:</p>
<table cellpadding="5">
<!-- cols="5 95" -->
<tr>
<td align="left" valign="top"><em>0</em></td>
<td align="left" valign="top">The user profile that owns the entry and a user
with *ALLOBJ authority is allowed to retrieve and update the entry.</td>
</tr>
<tr>
<td align="left" valign="top"><em>1</em></td>
<td align="left" valign="top">Any user can retrieve and update the entry
associated with this key.</td>
</tr>
</table>
<p><strong>Bytes available.</strong> The number of bytes of information
available to be returned to the user.</p>
<p><strong>Bytes returned.</strong> The number of bytes of information returned
to the user.</p>
<p><strong>Data.</strong> The data associated with the specified key.</p>
<p><strong>Entry status.</strong> Indicates whether the entry is in conflict or
not. An entry is in conflict if it is not the same on all nodes in the
clustered hash table domain. A potential cause of an entry in conflict is the
clustered hash table domain nodes were not communicating and the information
associated with the key was updated from more than one cluster partition. The
entry was marked in conflict when the cluster partition was merged together.
For additional details on cluster node partitions, see
<a href="../rzaig/rzaigtroubleshootpartitionerrors.htm">Partition
errors</a>. The entry is not the same on all nodes in the clustered
hash table domain. To resolve an entry in conflict, use the
<a href="clchtstoreentry.htm">Store Clustered Hash Table Entry</a> (QcstStoreCHTEntry)
API to update the entry to the correct value. The possible values are:</p>
<table cellpadding="5">
<!-- cols="5 95" -->
<tr>
<td align="left" valign="top"><em>0</em></td>
<td align="left" valign="top">Entry is not in conflict in the clustered hash
table.</td>
</tr>
<tr>
<td align="left" valign="top"><em>1</em></td>
<td align="left" valign="top">Entry is in conflict in the clustered hash
table.</td>
</tr>
</table>
<p><strong>Length of data.</strong> Length of the data associated with the
specified key.</p>
<p><strong>Offset to data.</strong> The offset from the beginning of the
structure to the Data field.</p>
<p><strong>Owning user profile.</strong> The user profile that originally
stored the entry associated with this key.</p>
<p><strong>Storing user profile.</strong> The user profile that last stored the
entry associated with this key.<br>
</p>
<br>
<h3>Error Messages</h3>
<table width="100%" cellpadding="5">
<!-- cols="15 85" -->
<tr>
<th align="left" valign="top">Message ID</th>
<th align="left" valign="top">Error Message Text</th>
</tr>
<tr>
<td width="15%" valign="top">CPF3C1E E</td>
<td width="85%" valign="top">Required parameter &amp;1 omitted.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3C21 E</td>
<td align="left" valign="top">Format name &amp;1 is not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3C24 E</td>
<td align="left" valign="top">Length of receiver variable not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3C3C E</td>
<td align="left" valign="top">Value for parameter &amp;1 not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3CF1 E</td>
<td align="left" valign="top">Error code parameter not valid.</td>
</tr>
<tr>
<td align="left" valign="top">CPF3CF2 E</td>
<td align="left" valign="top">Error(s) occurred during running of &amp;1 API.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBB26 E</td>
<td align="left" valign="top">Cluster Resource Services not active or not responding.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBB4D E</td>
<td align="left" valign="top">Cluster Resource Services cannot process the request.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBD06 E</td>
<td align="left" valign="top">Key not found in clustered hash table &amp;1.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBD07 E</td>
<td align="left" valign="top">User profile &amp;1 not authorized to clustered hash table
entry.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBD09 E</td>
<td align="left" valign="top">Clustered hash table server &amp;1 not active or not
responding.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBD0A E</td>
<td align="left" valign="top">Clustered hash table server &amp;1 internal error.</td>
</tr>
<tr>
<td align="left" valign="top">CPFBD0B E</td>
<td align="left" valign="top">Connection handle not active.</td>
</tr>
</table>
<br>
<hr>
API introduced: V5R2
<hr>
<center>
<table cellpadding="2" cellspacing="2">
<tr align="center">
<td valign="middle" align="center"><a href="#Top_Of_Page">Top</a> | <a href=
"clust1a1.htm">Cluster APIs</a> | <a href="aplist.htm">APIs by
category</a></td>
</tr>
</table>
</center>
</body>
</html>