ibm-information-center/dist/eclipse/plugins/i5OS.ic.dm_5.4.0.1/rbal3s370.htm

100 lines
7.5 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="copyright" content="(C) Copyright IBM Corporation 2005" />
<meta name="DC.rights.owner" content="(C) Copyright IBM Corporation 2005" />
<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="concept" />
<meta name="DC.Title" content="Convert System/370 floating point and null fields" />
<meta name="abstract" content="To copy floating point fields and null fields that are in a System/370 format to an iSeries format, use FMTOPT(*CVTFLOAT) for the floating point fields and FMTOPT(*NULLFLAGS) for the null fields. You can use these two values together in one command: FMTOPT(*CVTFLOAT *NULLFLAGS)." />
<meta name="description" content="To copy floating point fields and null fields that are in a System/370 format to an iSeries format, use FMTOPT(*CVTFLOAT) for the floating point fields and FMTOPT(*NULLFLAGS) for the null fields. You can use these two values together in one command: FMTOPT(*CVTFLOAT *NULLFLAGS)." />
<meta name="DC.subject" content="conversion, System/370 floating point and null fields, System/370, converting floating point and null fields, copying, System/370 floating point and null fields, copying file" />
<meta name="keywords" content="conversion, System/370 floating point and null fields, System/370, converting floating point and null fields, copying, System/370 floating point and null fields, copying file" />
<meta name="DC.Relation" scheme="URI" content="rbal3copydbmbrfmt.htm" />
<meta name="DC.Relation" scheme="URI" content="rbal3errin.htm" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="rbal3s370" />
<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>Convert System/370 floating
point and null fields</title>
</head>
<body id="rbal3s370"><a name="rbal3s370"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Convert System/370 floating
point and null fields</h1>
<div><p>To copy floating point fields and null fields that are in a System/370™ format
to an <span class="keyword">iSeries™</span> format, use FMTOPT(*CVTFLOAT)
for the floating point fields and FMTOPT(*NULLFLAGS) for the null fields.
You can use these two values together in one command: FMTOPT(*CVTFLOAT *NULLFLAGS).</p>
<p>The FMTOPT(*CVTFLOAT) parameter on the CPYF command converts each floating
point field from System/370 hexadecimal
format to the IEEE format that is used by the <span class="keyword">iSeries</span>.
The CPYF command converts those fields that are identified by the external
description of the physical to-file.</p>
<p>The FMTOPT(*NULLFLAGS) parameter on the CPYF command takes the byte (or
flag) following each null-capable field and uses it to indicate if the corresponding
input field is null. The CPYF command takes the fields that are identified
as null-capable by the external description of the physical to-file. If the
byte (or flag) is blank (<span>X'40'</span>) or contains <span>X'00'</span>, the data
is considered not null. Any other value for the flag causes the corresponding
input field data to be ignored and the output value set to null.</p>
<p>If you use *CVTFLOAT or *NULLFLAGS and the input file is externally described,
the input file's external description is not used in mapping the copied data.</p>
<p>When you use *CVTFLOAT and *NULLFLAGS (together or independently), make
certain that the to-file is an existing database, externally-described, physical
data file.</p>
<div class="p">You cannot specify the *CVTFLOAT and *NULLFLAGS values when any of the
following conditions are true: <ul><li>You have specified RCDFMT(*ALL) for a multiple-format logical from-file</li>
<li>You have specified any value other than the default for CRTFILE, and the
to-file does not exist</li>
<li>You have specified a value other than the default for the FROMKEY, TOKEY,
INCCHAR, INCREL, SRCOPT, or SRCSEQ parameters.</li>
</ul>
</div>
<p>When you specify either *CVTFLOAT or *NULLFLAGS, all other values for the
FMTOPT parameter are ignored. If you use both *CVTFLOAT and *NULLFLAGS on
one CPYF command, both values are recognized.</p>
<p>When you specify the *CVTFLOAT value (and have not specified *NULLFLAGS),
the expected from-file record length is the to-file record length. When you
have specified the *NULLFLAGS value, the expected from-file record length
is equal to the sum of the to-file record length and the number of null-capable
fields in the to-file. The from-file's record length cannot be less than the
expected length. If the from-file's record length is greater than the expected
length, an inquiry message is sent to the QSYSOPR message queue to determine
if the user wants to continue. If the user continues, the trailing data (fields)
in the from-file is truncated in the to-file.</p>
<p>The to-file must contain the correct result format description. The from-file
data must be in the same corresponding position as the to-file data. Otherwise,
output mapping errors or unpredictable results might occur. Date, time, and
timestamp data must be in the external form of the to-file field specification.
Numeric data types in the to-file must be large enough to contain the expected
data. For example, decimal data types in the to-file must be created using
the maximum possible precision for the byte length of the field to avoid the
loss of any digits. Because there are no CCSID conversions, the to-file fields
should be created with the expected CCSIDs.</p>
<p>For more information about converting floating points and null fields,
see <a href="rbal3errin.htm#rbal3errin">Errors in converting System/370 floating point and null fields</a>.</p>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="rbal3errin.htm">Errors in converting System/370 floating point and null fields</a></strong><br />
Any conversion errors will cause CPF2958 messages to be issued for up to 10 records with errors. A CPF2959 message will be issued after the copy operation; this message indicates the number of records that caused an error if more than 10 records caused conversion errors.</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="rbal3copydbmbrfmt.htm" title="When you copy from a database file to a database file, you must use the FMTOPT parameter if the record formats are not identical or if the files are different types (source or data). If either file is a device file or inline data file, the FMTOPT parameter does not apply. The records are truncated or padded with blanks or zeros when record lengths are different. A message is sent if the records are truncated.">Copying between different database record formats (FMTOPT parameter)</a></div>
</div>
</div>
</body>
</html>