https://m204wiki.rocketsoftware.com/index.php?title=IFDFLD_(HLI_function)&feed=atom&action=historyIFDFLD (HLI function) - Revision history2024-03-28T10:59:57ZRevision history for this page on the wikiMediaWiki 1.40.1https://m204wiki.rocketsoftware.com/index.php?title=IFDFLD_(HLI_function)&diff=89149&oldid=prevELowell at 22:10, 12 July 20162016-07-12T22:10:36Z<p></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 22:10, 12 July 2016</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l1">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>The conventions used on this page are described in [[HLI: Function <del style="font-weight: bold; text-decoration: none;">call list</del>#Function call notation conventions|Function call notation conventions]].</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>The conventions used on this page are described in [[HLI: Function <ins style="font-weight: bold; text-decoration: none;">summary</ins>#Function call notation conventions|Function call notation conventions]].</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>==Summary==</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>==Summary==</div></td></tr>
</table>ELowellhttps://m204wiki.rocketsoftware.com/index.php?title=IFDFLD_(HLI_function)&diff=88475&oldid=prevELowell at 21:14, 11 July 20162016-07-11T21:14:21Z<p></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 21:14, 11 July 2016</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l1">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">The conventions used on this page are described in [[HLI: Function call list#Function call notation conventions|Function call notation conventions]].</ins></div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>==Summary==</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>==Summary==</div></td></tr>
</table>ELowellhttps://m204wiki.rocketsoftware.com/index.php?title=IFDFLD_(HLI_function)&diff=84752&oldid=prevELowell: Created page with " ==Summary== <dl> <dt>Description</dt> <dd>The IFDFLD call (DEFINE FIELD) defines a new field for a Model 204 file.</dd> <dt>Thread type</dt> <dd>multiple cursor IFSTRT, singl..."2016-07-06T17:03:36Z<p>Created page with " ==Summary== <dl> <dt>Description</dt> <dd>The IFDFLD call (DEFINE FIELD) defines a new field for a Model 204 file.</dd> <dt>Thread type</dt> <dd>multiple cursor IFSTRT, singl..."</p>
<p><b>New page</b></p><div><br />
==Summary==<br />
<dl><br />
<dt>Description</dt><br />
<dd>The IFDFLD call (DEFINE FIELD) defines a new field for a Model 204 file.</dd><br />
<dt>Thread type</dt><br />
<dd>multiple cursor IFSTRT, single cursor IFSTRT </dd><br />
<dt>IFCALL function number</dt><br />
<dd>24</dd><br />
</dl><br />
<br />
==Syntax==<br />
<p class="syntax">IFDFLD(RETCODE,FIELD_DESC,FILE_SPEC)</p><br />
<dl><br />
<dt>Compile-only form</dt><br />
<dd>Not available</dd><br />
<dt>Execute-only form</dt><br />
<dd>Not available</dd><br />
</dl><br />
<br />
<p>Specify the parameters in the syntax order shown above. </p><br />
<table><br />
<tr class="head"><br />
<th>Parameter</th><br />
<th>Description</th><br />
</tr><br />
<tr><br />
<td>RETCODE</td><br />
<td>[O,i,r] The Model 204 return code is the required first parameter. The code is a binary integer value.</td><br />
</tr><br />
<tr><br />
<td>FIELD_DESC</td><br />
<td>[I,c,r] The field description is a required input parameter that specifies the name of the new field and a list of its attributes. Specify the field as a character string using the following format:<br />
<p class="syntax"><span class="term">fieldname</span> [(<span class="term">attribute</span> ...)];</p><br />
<p>where:</p><br />
<p><br />
<var class="term">fieldname</var> is required and specifies the name of the new field. The name must be unique within the context of the file where it will be stored. </p><br />
<p><br />
Specify the name as a character string up to 255 characters in length. The name must begin with a letter and it can contain any alphanumeric character <I>except</I> the following:</p><br />
<ul><br />
<li>At sign (@)</li><br />
<li>Pound sign (#)</li><br />
<li>Semi-colon (;)</li><br />
<li>Double question marks (??)</li><br />
<li>Question mark followed by a dollar sign (?$)</li><br />
<li>Question mark followed by an ampersand (?&amp;)</li><br />
</ul><br />
<p><br />
For the detailed list of rules that apply to naming fields, see [[Field names]].</p><br />
<p><br />
<var class="term">attribute</var> is optional and specifies a particular characteristic that controls how the field is used, stored, or accessed. You can specify more than one attribute, separating each by a comma or a blank. </p><br />
<p><br />
The attributes that can be specified using the IFDFLD call are identical to those that are used with the <var>[[DEFINE FIELD command|DEFINE FIELD]]</var> command. For more information, see [[Field design#Field descriptions and attributes|Field descriptions and attributes]].</p><br />
<br />
<p class="note"><b>Note:</b> If no attributes are specified, Model 204 defines the field assigning all of the default attributes.</p><br />
</td><br />
</tr><br />
<tr><br />
<td>FILE_SPEC</td><br />
<td>[I,s,o] The file specification is an optional input parameter for use only with a multiple cursor IFSTRT thread; it specifies the name of the Model 204 file that will contain the new field. Specify the name of the file as a short character string variable using the following format: <br />
<p class="syntax">IN [FILE] <span class="term">filename</span></p><br />
<p><br />
The specified file must be open on the thread, otherwise the call is unsuccessful and Model 204 returns a completion code equal to 4.</p><br />
</td><br />
</tr><br />
</table><br />
<br />
==Usage notes==<br />
<p><br />
Use the IFDFLD call to define a new field in a Model 204 file. The IFDFLD call is valid on all types of IFSTRT threads. You can use the IFDFLD call once the Model 204 file has been initialized (using the IFINIT call). </p><br />
<p><br />
When FOPT=X'10' and the date/time stamp feature is installed, the IFDFLD function is supported for DTS files.</p><br />
<br />
<p class="note"><b>Note:</b> The file context can change on a multiple cursor thread and, if the file specification parameter (FILE_SPEC) is omitted, IFDFLD defines the field for the default file on the thread. </p><br />
<p><br />
Note that certain types of fields must be defined using [[IFINIT (HLI function)|IFINIT]] rather than IFDFLD. You cannot use IFDFLD to define fields when:</p><br />
<ul><br />
<li>Record security is defined using the field</li><br />
<li>The field is defined as a sort key</li><br />
<li>The field is used as a hash key</li><br />
</ul><br />
<p><br />
Note also that IFDFLD follows the same basic rules for specifying field attribute definitions as the Model 204 <var>[[DEFINE FIELD command|DEFINE FIELD]]</var> command. </p><br />
<p><br />
For more information, see [[Field design#Field descriptions and attributes|Field descriptions and attributes]].</p><br />
<br />
==Coding example (COBOL)==<br />
<p class="code">WORKING-STORAGE SECTION.<br />
01 CALL-ARGS.<br />
05 RETCODE PIC 9(5) COMP SYNC.<br />
05 FIELDA PIC X(20) VALUE "FIELDA(BINARY KEY);".<br />
05 FIELDB PIC X(32) VALUE "FIELDB(FEW-VALUED,CODED,<br />
RANGE);".<br />
.<br />
.<br />
.<br />
PROCEDURE DIVISION.<br />
.<br />
.<br />
.<br />
CALL "IFDFLD" USING RETCODE, FIELDA, FIELDB.</p><br />
<br />
[[Category: HLI functions]]</div>ELowell