ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzalu_5.4.0.1/rzalueof.htm

91 lines
5.4 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 xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="dc.language" scheme="rfc1766" 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. -->
<meta name="dc.date" scheme="iso8601" content="2005-09-06" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1998, 2006" />
<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))' />
<title>Output field considerations</title>
<link rel="stylesheet" type="text/css" href="ibmidwb.css" />
<link rel="stylesheet" type="text/css" href="ic.css" />
</head>
<body>
<a id="Top_Of_Page" name="Top_Of_Page"></a><!-- Java sync-link -->
<script language = "Javascript" src = "../rzahg/synch.js" type="text/javascript"></script>
<a name="rzalueof"></a>
<h4 id="rzalueof">Output field considerations</h4>
<p>The system provides editing support that makes fields more readable when
they are printed. With the system editing support, you can do the following: </p>
<ul>
<li>Suppress leading zeros</li>
<li>Punctuate a field with commas and periods to show decimal column and to
group digits in sets of three</li>
<li>Print negative values with a minus sign or CR to the right</li>
<li>Print zero values as zeros or blanks</li>
<li>Print asterisks to the left of significant digits to provide asterisk
protection</li>
<li>Print a currency symbol corresponding to the system value Currency symbol
(QCURSYM)</li></ul>
<p>The system provides this editing support with edit codes and edit words.
Edit codes are a defined set of editing patterns. You identify these by
name, and the system edits a field according to the pattern defined by the
named edit code. Edit words are edit patterns that you define to produce the
results that you want. Edit codes include most commonly used editing requirements.
You need to use the edit word support only for those editing needs not included
by edit codes.</p>
<p>There are two methods of using edit codes and edit words. Which one you
use depends on how you define the printer file and how it is used in an application
program. If your application is using program-described data, your high-level
language might allow you to identify edit codes or create your own edit words.
If your application is using externally described data, the edit code (EDTCDE)
DDS keyword allows you to identify an edit code; the edit word (EDTWRD) DDS
keyword allows you to define your own editing pattern.</p>
<p>The system provides several edit codes: </p>
<ul>
<li>1 through 4</li>
<li>A through D</li>
<li>J through M</li>
<li>X through Z</li></ul>
<p>The editing patterns defined by these codes are described in <a href="../rzahg/rzahgdds.htm">DDS Reference</a> in the Programming topic.</p>
<p><span class="bold">User-defined edit codes</span></p>
<p>You can also define five edit codes to provide more editing function than
is available with the i5/OS edit codes, and to handle common editing functions
that would otherwise require the use of an edit word. These are called user-defined
edit codes. For example, you might need to edit numbers that include hyphens
(like some telephone numbers), or more than one decimal point. You can use
user-defined edit codes for these functions. These edit codes are named QEDIT5,
QEDIT6, QEDIT7, QEDIT8, and QEDIT9 and can be referred to in DDS or a high-level
language program by number (5, 6, 7, 8, or 9).</p>
<p>These edit codes are created by using the Create Edit Description (CRTEDTD)
command. Edit descriptions are always placed in library QSYS. They cannot
be moved or renamed; only one occurrence of each is allowed. Edit descriptions
have an object type of *EDTD.</p>
<p>IBM&reg; supplies a version of each of the QEDIT edit codes. You can use
these edit descriptions as they are, or you can delete them and create your
own. See <a href="../rzahg/rzahgdds.htm">DDS Reference</a> in the Programming topic for
more information about using these edit descriptions.</p>
<p>Before using any of the user-defined edit codes, you should check its contents
on your system, since it might have been changed from the IBM-supplied version.
The Display Edit Description (DSPEDTD) command can be used to display the
contents of a user-defined edit code.</p>
<p>Changing a user-defined edit code description does not affect any application
or printer file that has already been created using that edit description.
If you want your application to use the changed edit description, you must
either create the high-level language program again (if the edit code is used
in the program) or create the file again (if the application is using an externally
described file that contains EDTCDE keywords).</p>
<a id="Bot_Of_Page" name="Bot_Of_Page"></a>
</body>
</html>