ibm-information-center/dist/eclipse/plugins/i5OS.ic.dds_5.4.0.1/sflpagexamp.htm

142 lines
8.0 KiB
HTML
Raw Permalink Normal View History

2024-04-02 14:02:31 +00:00
<?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="concept" />
<meta name="DC.Title" content="Example: A subfile with SFLPAG value equal to SFLSIZ value" />
<meta name="abstract" content="The display is defined by the DDS in this example. It is displayed by an output operation to the subfile control-record format SFLCTL1." />
<meta name="description" content="The display is defined by the DDS in this example. It is displayed by an output operation to the subfile control-record format SFLCTL1." />
<meta name="DC.subject" content="examples of DDS, subfile" />
<meta name="keywords" content="examples of DDS, subfile" />
<meta name="DC.Relation" scheme="URI" content="rbafpmstexamp.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1999, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1999, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="sflpagexamp" />
<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>Example: A subfile with SFLPAG value equal to SFLSIZ value</title>
</head>
<body id="sflpagexamp"><a name="sflpagexamp"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Example: A subfile with SFLPAG value equal to SFLSIZ value</h1>
<div><p>The display is defined by the DDS in this example. It is displayed
by an output operation to the subfile control-record format SFLCTL1.</p>
<pre class="screen">
First Field Second Field
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
</pre>
<p>The following keywords are important in the example:</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" width="100%" frame="void" border="0" rules="none"><tbody><tr><td valign="top" width="50%"> <p>ROLLDOWN<br />
ROLLUP<br />
SFLCLR<br />
SFLDSP</p>
</td>
<td valign="top" width="50%"> <p>SFLDSPCTL<br />
SFLPAG<br />
SFLSIZ</p>
</td>
</tr>
</tbody>
</table>
</div>
<p>The file in <a href="#sflpagexamp__o10">Figure 1</a> has one column of subfile
records. Constant fields in the subfile control-record format are used as
headings for columns of fields in the subfile records.</p>
<div class="fignone" id="sflpagexamp__o10"><a name="sflpagexamp__o10"><!-- --></a><span class="figcap">Figure 1. Subfile with subfile size equal to subfile page</span><pre>|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8
00010A* USE OF SUBFILE KEYWORDS
00020A <strong>(1)</strong> R SFL1 SFL
00030A <strong>(2)</strong> FLD1 10 0I 3 11
00040A <strong>(2)</strong> FLD2 16 O 3 26
00050A
00060A <strong>(1)</strong> R SFLCTL1 SFLCTL(SFL1)
00070A SFLSIZ(18) <strong>(3)</strong>
00080A SFLPAG(18) <strong>(3)</strong>
00090A 05 SFLDSP <strong>(4)</strong>
00100A 05 SFLDSPCTL <strong>(4)</strong>
00110A N05 SFLCLR <strong>(5)</strong>
00120A ROLLUP(01) ROLLDOWN(02)<strong>(6)</strong>
00130A 1 11'First Field' <strong>(7)</strong>
00140A 1 26'Second Field' <strong>(7)</strong>
A</pre>
</div>
<div class="p"><strong>Legend:</strong> <dl><dt class="dlterm">(1)</dt>
<dd>The subfile record format SFL1 and the subfile control-record format SFLCTL1
together define one subfile. The parameter value for the SFLCTL keyword is
the name of the subfile record format.</dd>
<dt class="dlterm">(2)</dt>
<dd>Each subfile record is made up of two fields: FLD1 and FLD2. FLD1 is
10 bytes long (11 bytes display length because it defaults to signed numeric);
FLD2 is 16 bytes long. FLD1 is an input-only field; FLD2 is an output-only
field. Eighteen subfile records appear on the display, with the first one
on line 3 and the last one on line 20. For each subfile record on the display,
two fields (FLD1 and FLD2) appear, with four spaces between FLD1
and FLD2.</dd>
<dt class="dlterm">(3)</dt>
<dd>SFLSIZ and SFLPAG (required keywords) have equal values (18). Therefore
one page equals the whole subfile. For all subfiles, the value of the SFLPAG
keyword is the number of subfile records displayed at any one time (unless
the SFLDROP keyword or variable-length records are used).</dd>
<dt class="dlterm">(4)</dt>
<dd>SFLDSP (a required keyword) and SFLDSPCTL (an optional keyword) are specified
with indicator 05. Therefore, when indicator 05 is set on, the subfile and
subfile control records can be displayed by an output operation to the subfile
control-record format SFLCTL1.</dd>
<dt class="dlterm">(5)</dt>
<dd>SFLCLR (an optional keyword) is specified with option indicator 05 preceded
by an N. When indicator 05 is set off, the subfile can be cleared by an output
operation to SFLCTL1.</dd>
<dt class="dlterm">(6)</dt>
<dd>ROLLUP (an optional keyword) is specified with response
indicator 01, and ROLLDOWN (an optional keyword) is specified with response
indicator 02. Note also that the entire subfile equals one page, which means
that the whole subfile is displayed at one time. Therefore, when the display
station user presses the Page Up key, control passes to the program with indicator
01 on, and when the workstation user presses the Page Down key, control passes
to the program with indicator 02 on. The program must handle paging, by reading,
clearing, rewriting, and redisplaying the subfile. Without ROLLUP and ROLLDOWN
specified, the workstation user will receive an error message when pressing
the Page Up or Page Down key.</dd>
<dt class="dlterm">(7)</dt>
<dd>Two constants ('First Field' and 'Second Field') are displayed when the
subfile control-record is displayed (SFLDSPCTL in effect). As specified in
this subfile, they act as column headings to the subfile records.</dd>
</dl>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="rbafpmstexamp.htm" title="This topic provides examples of data description specifications (DDS) for each type of file discussed in this topic. If you choose, you can use the examples in this topic with appropriate high-level language programs.">Examples: DDS for each file type</a></div>
</div>
</div>
</body>
</html>