ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzakc_5.4.0.1/rzakcmstdfptret.htm

133 lines
8.3 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="PUTRETAIN (Put-Retain) keyword for display files" />
<meta name="abstract" content="Use this record- or field-level keyword with the OVERLAY keyword so that the i5/OS operating system does not delete data already on the display when displaying a record again. The PUTOVR keyword has a function similar to, but more effective than, PUTRETAIN." />
<meta name="description" content="Use this record- or field-level keyword with the OVERLAY keyword so that the i5/OS operating system does not delete data already on the display when displaying a record again. The PUTOVR keyword has a function similar to, but more effective than, PUTRETAIN." />
<meta name="DC.subject" content="PUTRETAIN (Put-Retain) keyword" />
<meta name="keywords" content="PUTRETAIN (Put-Retain) keyword" />
<meta name="DC.Relation" scheme="URI" content="rzakcmstkeyent.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 2001, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 2001, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="rzakcmstdfptret" />
<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>PUTRETAIN (Put-Retain) keyword for display files</title>
</head>
<body id="rzakcmstdfptret"><a name="rzakcmstdfptret"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">PUTRETAIN (Put-Retain) keyword for display files</h1>
<div><p>Use this record- or field-level keyword with the OVERLAY keyword
so that the <span class="keyword">i5/OS™</span> operating
system does not delete data already on the display when displaying a record
again. The PUTOVR keyword has a function similar to, but more effective than,
PUTRETAIN.</p>
<div class="section"><p>This keyword has no parameters.</p>
<p>To understand what effect
this keyword has on output operations, consider the following sequence of
steps:</p>
<ol><li>Your program sends an output operation to RECORD1, displaying RECORD1.
PUTRETAIN, if in effect, is ignored. Any data in the record area for RECORD1
is deleted before RECORD1 is displayed.</li>
<li>At some later time, with RECORD1 still on the display, your program sends
a second output operation to RECORD1. Two conditions can occur: <ul><li>If the PUTRETAIN keyword is not in effect, the <span class="keyword">i5/OS</span> operating
system first deletes the record area for RECORD1, then displays RECORD1. Fields
selected for display at this time are displayed with new data contents and
new display attributes, which can be the same as before. The record area includes
every line on which a field or part of a field for RECORD1 appears.</li>
<li>If PUTRETAIN is in effect, the <span class="keyword">i5/OS</span> operating
system does not delete the record area for RECORD1. The data contents of selected
fields are not changed. However, the display attributes for selected fields
are sent to the display and can be changed (by selecting which DSPATR keyword
is in effect for this output operation). Fields not selected for display are
written over character-by-character by fields selected for display. (For more
information, see the <a href="#rzakcmstdfptret__whenf">When fields are selected
by option indicators</a> section in this topic.)</li>
</ul>
</li>
</ol>
<div class="note"><span class="notetitle">Note:</span> When using the field-level PUTRETAIN keyword, the entire record
area is deleted if none of the fields in the record has PUTRETAIN optioned
on. If you specify at least one field with unoptioned field-level PUTRETAIN
keyword, this ensures that the record area is not deleted.</div>
<p>If you
specify the PUTRETAIN keyword, you should also specify RSTDSP(*YES) on the
Create Display File (CRTDSPF) or Change Display File (CHGDSPF) command. Otherwise,
data on the display can be lost if the file is suspended.</p>
<p>Option indicators
are valid for this keyword.</p>
</div>
<div class="section"><h4 class="sectiontitle">Conditions affecting the PUTRETAIN keyword</h4><p>PUTRETAIN
applies only to the record format for which it is specified, and then only
if the record is already displayed. If the record on which PUTRETAIN is specified
is not on the display, PUTRETAIN is ignored.</p>
<p>If you specify this keyword
at the record level, the keyword applies to all fields in the record format
that are selected for display.</p>
<p>This keyword can be specified for more
than one field of a record format, but only once per field. This keyword can
be specified at the record level and at the field level within the same record
format.</p>
<p>PUTRETAIN cannot be specified with the PUTOVR keyword.</p>
<p>A
warning message appears at file creation time if the PUTRETAIN keyword is
specified on a record with the DSPMOD keyword. At run time, the PUTRETAIN
keyword is ignored when the display mode changes.</p>
<p>The OVERLAY keyword
must be specified whenever PUTRETAIN is specified.</p>
<p>If the OVERLAY keyword
is not in effect, PUTRETAIN is ignored and the entire display deleted before
the record is displayed.</p>
</div>
<div class="section" id="rzakcmstdfptret__whenf"><a name="rzakcmstdfptret__whenf"><!-- --></a><h4 class="sectiontitle">When fields are selected by option indicators</h4><p>When
PUTRETAIN is in effect on an output operation involving field selection, fields
in the record format that are not selected for redisplay are not deleted;
they can be partially or completely rewritten by newly selected fields.</p>
<p>If
PUTRETAIN is in effect only for a newly selected field (specified at the field
level), only the beginning attribute character of the field is sent to the
display; the ending attribute character is not sent. For fields without PUTRETAIN
in the same record format, the <span class="keyword">i5/OS</span> operating
system sends the display attribute and the data. If PUTRETAIN is in effect
for the whole record (specified at the record level), only the beginning and
ending attribute characters are sent to the display. Thus, the display attribute
of a field can be reset to normal if the field immediately preceding this
field is selected and this field is not selected.</p>
<p>For example, assume
that the DSPATR(UL) keyword is in effect for two consecutive fields with overlapping
attribute characters. If on an output operation with PUTRETAIN in effect,
the first of these fields is selected and the second field is not selected,
the display attribute of the second field is reset to the normal display attribute.
This is because the <span class="keyword">i5/OS</span> operating
system sends the first field to the display with beginning and ending attribute
characters, and its ending attribute character overrides the beginning attribute
character of the second field.</p>
</div>
<div class="example"><h4 class="sectiontitle">Example</h4><p>The following example shows how to specify
the PUTRETAIN keyword.</p>
<pre>|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8
00101A R CUST
00102A PUTRETAIN OVERLAY
A</pre>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="rzakcmstkeyent.htm" title="You type the keyword entries that define display files in positions 45 through 80 (functions).">DDS keyword entries for display files (positions 45 through 80)</a></div>
</div>
</div>
</body>
</html>