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

332 lines
9.7 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>Get Short Form with Maximal CS for Specified ES and CP (QTQSMXC2)
API</title>
<!-- Begin Header Records ========================================== -->
<!-- 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 -->
<!-- NETMG2 SCRIPT A converted by B2H R4.1 (346) (CMS) by HOLTJM at -->
<!-- RCHVMW2 on 29 Jan 1999 at 10:01:37 -->
<!--File Edited December 2001 -->
<!--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>Get Short Form with Maximal CS for Specified ES and CP (QTQSMXC2) API</h2>
<div class="box" style="width: 60%;">
<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%">CPIN</td>
<td align="left" valign="top" width="20%">Input</td>
<td align="left" valign="top" width="20%">Int(4)</td>
</tr>
<tr>
<td align="center" valign="top">2</td>
<td align="left" valign="top">ESIN</td>
<td align="left" valign="top">Input</td>
<td align="left" valign="top">Int(4)</td>
</tr>
<tr>
<td align="center" valign="top">3</td>
<td align="left" valign="top">CCSIDR</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Int(4)</td>
</tr>
<tr>
<td align="center" valign="top">4</td>
<td align="left" valign="top">ESR</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Int(4)</td>
</tr>
<tr>
<td align="center" valign="top">5</td>
<td align="left" valign="top">FB</td>
<td align="left" valign="top">Output</td>
<td align="left" valign="top">Feedback</td>
</tr>
</table>
<br>
&nbsp;&nbsp;Default Public Authority: *USE<br>
<!-- iddvc RMBR -->
<br>
&nbsp;&nbsp;Threadsafe: Yes<br>
<!-- iddvc RMBR -->
<br>
</div>
<p>The Get Short Form with Maximal CS for Specified ES and CP (QTQSMXC2) API
gets the CCSID with the maximal character set (CS) for a given code page (CP)
value. The encoding scheme (ES) parameter can be specified to distinguish
between usage of the same CP with two different encoding schemes, such as PC
Display compared to PC Data.</p>
<p>The CS element that is associated with the returned CCSID is the largest in
size of all the character sets that are contained in the associated code page
for that CS element in the CCSID resource installed on the system.</p>
<p>The QTQSMXC2 API acts as an extension of the functions of the CDRSMXC API in
that you can specify more code pages. The additional code pages are as
follows:</p>
<ul>
<li>932</li>
<li>934</li>
<li>936</li>
<li>938</li>
<li>942</li>
<li>944</li>
<li>946</li>
<li>948</li>
<li>949</li>
<li>950</li>
<li>1381</li>
</ul>
<p><strong>Note:</strong> Not all the registered code pages are full, leaving
room for possible future additions. The term maximal is used to distinguish it
from a full code page. Over time, when new larger character sets are registered
for a code page (this can happen until the code page is full), the maximal
character set also changes, leading to a new CCSID returned by this
function.</p>
<br>
<!-- Please NOTE: DO NOT DELETE THIS SECTION if this API has no authorities and locks. -->
<!-- Instead, use the commented out coding below to indicate NONE. -->
<h3>Authorities and Locks</h3>
<!-- Use this if there are no authorities and locks. -->
<p>None.</p>
<br>
<h3>Required Parameters</h3>
<dl>
<dt><strong>CPIN</strong></dt>
<dd>INPUT; INT(4)
<p>A variable that contains the CP value referenced. This value must be a
positive number in the range 1 to 65&nbsp;534.</p>
</dd>
<dt><strong>ESIN</strong></dt>
<dd>INPUT; INT(4)
<p>A variable that contains the ES value referenced.</p>
<p>Possible values follow:</p>
<table cellpadding="3">
<!-- cols="10 90" -->
<tr>
<td align="left" valign="top"><em>0</em></td>
<td valign="top">The caller does not know the ES value, and expects the first
CCSID encountered in the CCSID repository, with the specified CP and the full
or maximal CS, to be returned.</td>
</tr>
<tr>
<td align="left" valign="top"><em>4352-65&nbsp;534</em></td>
<td valign="top">The caller specifies the encoding scheme value. Only encoding
schemes that have a single (CS, CP) pair associated with them are valid for
this function.</td>
</tr>
</table>
<br>
</dd>
<dt><strong>CCSIDR</strong></dt>
<dd>OUTPUT; INT(4)
<p>A variable that contains the returned CCSID value. This value must be a
positive number in the range 1 to 65&nbsp;279.</p>
</dd>
<dt><strong>ESR</strong></dt>
<dd>OUTPUT; INT(4)
<p>A variable that contains the ES value of the returned CCSID. This value must
be zero or a positive number in the range 4352 to 65&nbsp;534.</p>
</dd>
<dt><strong>FB</strong></dt>
<dd>OUTPUT; FEEDBACK
<p>In this feedback array this function returns the processing status (and any
associated reason) for this function. The field type is an array of three
32-bit two's complement binary values (12 bytes or 96 bits). The status code is
a non-negative number in the first 16 bits, and the reason code is a
non-negative number in the second 16 bits. The following are specific meanings
of the status code and associated reason code values (in hexadecimal) contained
in the first 32 bits of FB. The other 64 bits are reserved.</p>
</dd>
</dl>
<br>
<h3>Feedback Codes and Conditions</h3>
<table border width="80%">
<tr>
<th align="center" valign="top">Status</th>
<th align="center" valign="top">Reason</th>
<th align="left" valign="top">Meaning</th>
</tr>
<tr>
<td align="center" valign="top" width="10%">0000</td>
<td align="center" valign="top" width="10%">0000</td>
<td align="left" valign="top" width="80%">The function completed
successfully.</td>
</tr>
<tr>
<td align="center" valign="top">0001</td>
<td align="center" valign="top">0001</td>
<td align="left" valign="top">No entry was found in the CCSID
resource repository for the specified CPIN, ESIN combination.</td>
</tr>
<tr>
<td align="center" valign="top">0001</td>
<td align="center" valign="top">0003</td>
<td align="left" valign="top">The ESIN was specified as 0. The
first CCSID encountered in the CCSID repository, with the specified CP and the
full or maximal CS, was returned. Additional CCSIDs meeting the criteria may
exist.</td>
</tr>
<tr>
<td align="center" valign="top">0001</td>
<td align="center" valign="top">0009</td>
<td align="left" valign="top">The ESIN specified indicates that
more than one pair of CS, CPs are associated with it, which is incorrect for
this function.</td>
</tr>
<tr>
<td align="center" valign="top">0002</td>
<td align="center" valign="top">0001</td>
<td align="left" valign="top">The CPIN value is 0.</td>
</tr>
<tr>
<td align="center" valign="top">0003</td>
<td align="center" valign="top">0001</td>
<td align="left" valign="top">The CPIN value is 65&nbsp;535
(X'0000FFFF').</td>
</tr>
<tr>
<td align="center" valign="top">0006</td>
<td align="center" valign="top">0001</td>
<td align="left" valign="top">The CCSID resource repository was not
found.</td>
</tr>
<tr>
<td align="center" valign="top">0006</td>
<td align="center" valign="top">0002</td>
<td align="left" valign="top">The CCSID resource repository is
currently unavailable.</td>
</tr>
<tr>
<td align="center" valign="top">0007</td>
<td align="center" valign="top">0001</td>
<td align="left" valign="top">The system CCSID resource repository
accessed by the function was found to be incorrect in the structure.</td>
</tr>
<tr>
<td align="center" valign="top">0008</td>
<td align="center" valign="top">0001</td>
<td align="left" valign="top">The CPIN value is not in the range 0
(X'00000000') to 65&nbsp;535. (X'0000FFFF').</td>
</tr>
<tr>
<td align="center" valign="top">0008</td>
<td align="center" valign="top">0009</td>
<td align="left" valign="top">The ESIN value is nonzero and not in
the range 4352 (X'00001100') to 65&nbsp;534 (X'0000FFFE').</td>
</tr>
</table>
<br>
<br>
<h3>Usage Notes</h3>
<ol>
<li>Often it is required to find the CCSID when the ES, CS, and CP values are
known. CS and CP (also known as CGCSGID or GCID) are used in many existing IBM
architectures, data streams, and supporting products. Together with the CDRSCSP
API, this function aids in the coexistence and migration for products that have
to deal with the short form (CCSID) of identification on one side and the
intermediate form (the code page global identifier) on the other. Because the
intermediate forms are, by themselves, incomplete when used in some encoding
schemes, the function can return only a default value as defined in the
installation's resources, when the ESIN information is unknown.<br>
<br>
</li>
<li>When an ESIN value of zero is specified, the feedback code is never
returned as zero. Absence of an error results in a 0001 0003 feedback
code.</li>
</ol>
<hr>
API introduced: V4R1
<hr>
<center>
<table cellpadding="2" cellspacing="2">
<tr align="center">
<td valign="middle" align="center"><a href="#Top_Of_Page">Top</a> | <a href=
"nls1.htm">National Language Support APIs</a> | <a href="aplist.htm">APIs by
category</a></td>
</tr>
</table>
</center>
</body>
</html>