FastUnload (Recordset function): Difference between revisions
m (minor word change) |
|||
(4 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{Template:Recordset:FastUnload subtitle}} | {{Template:Recordset:FastUnload subtitle}} | ||
This [[Notation conventions for methods#Callable functions|callable]] method performs synchronous or asynchronous [[Fast/Unload|unloads]] of the records in the <var>Recordset</var> method object using the <var class="product">[[Fast/Unload SOUL Interface]]</var>. | |||
This [[Notation conventions for methods#Callable functions|callable]] method performs synchronous or asynchronous unloads of the records in the <var>Recordset</var> method object using the <var class="product">[[Fast/Unload SOUL Interface]]</var>. | |||
This method is only available to customers that are also licensed for | This method is only available to customers that are also licensed for | ||
Line 53: | Line 52: | ||
This is an optional, [[Notation conventions for methods#Named parameters|name required]], parameter, and it defaults to <var>False</var>. That is, many informational messages are suppressed from the report output by default.</p></td></tr> | This is an optional, [[Notation conventions for methods#Named parameters|name required]], parameter, and it defaults to <var>False</var>. That is, many informational messages are suppressed from the report output by default.</p></td></tr> | ||
<tr><th><var>Asynch</var></th> | <tr id="asynch"><th><var>Asynch</var></th> | ||
<td>A <var>Boolean</var> value: | <td>A <var>Boolean</var> value: | ||
<ul> | <ul> | ||
Line 59: | Line 58: | ||
<li>If <var>False</var>, the <var>FastUnload</var> method does not return until the unload is completed, if no errors are detected. In such a case, the return code from the method is the return code from <var class="product">Fast/Unload</var>. | <li>If <var>False</var>, the <var>FastUnload</var> method does not return until the unload is completed, if no errors are detected. In such a case, the return code from the method is the return code from <var class="product">Fast/Unload</var>. | ||
</ul> | </ul> | ||
This is an optional, name required, parameter, and it defaults to <var>False</var>.</td></tr> | This is an optional, name required, parameter, and it defaults to <var>False</var>. | ||
<p class="note"><b>Note:</b> <code>Asynch=True</code> specifies that the Fast/Unload request is run completely in the background. The <var>[[FastUnloadTask (Recordset function)|FastUnloadTask]]</var> method, on the other hand, runs a Fast/Unload request asynchronously with the SOUL request that invokes it, but the SOUL request will rendezvous with the Fast/Unload request, retrieving each output record in turn.</p></td></tr> | |||
<tr><th><var>Notify</var></th> | <tr><th><var>Notify</var></th> | ||
Line 114: | Line 115: | ||
==See also== | ==See also== | ||
<ul> | <ul> | ||
<li>The <var class="product">[[Fast/Unload]]</var> wiki pages. | |||
<li>The <var>[[FastUnloadTask (Recordset function)|FastUnloadTask]]</var> function, which allows SOUL processing of the Fast/Unload output as it is created. | <li>The <var>[[FastUnloadTask (Recordset function)|FastUnloadTask]]</var> function, which allows SOUL processing of the Fast/Unload output as it is created. | ||
</ul> | </ul> |
Latest revision as of 00:33, 14 October 2016
Unload Recordset using Fast/Unload User Language Interface (Recordset class)
[Requires Fast/Unload Soul Interface]
This callable method performs synchronous or asynchronous unloads of the records in the Recordset method object using the Fast/Unload SOUL Interface.
This method is only available to customers that are also licensed for the Fast/Unload SOUL Interface.
The FastUnload function also requires at least one Fast/Unload task to be available in the Online in which it is running, which means that the FUNTSKN system parameter must be set to 1 or higher.
Syntax
[%number =] recordset:FastUnload( [Input=] input, [Output=] output, - [[Report=] report], [[Parameters=] string], - [AllMessages= boolean], [Asynch= boolean], - [Notify= boolean], [MaxTime= number])
Syntax terms
%number | A numeric value, as follows:
|
---|---|
recordset | A reference to an instance of a Recordset object. |
Input | A Stringlist object that contains the Fast/Unload FUEL program for the unload, or a string that contains the DD name of the dataset which contains the FUEL program. This is a name allowed parameter. |
Output | A Stringlist object that is to receive the unloaded data, or a string that contains the DD name that is to receive the unloaded data.
If the request is asynchronous, and this parameter is a Stringlist object, the request is cancelled. This is a name allowed parameter. |
Report | A Stringlist object that is to receive the Fast/Unload report, or a string containing the DD name that is to receive the report.
If the request is asynchronous, and this parameter is a Stringlist object, the request is cancelled. This is an optional, name allowed, parameter. If it is not specified, the report goes to FUNAUDIT; if there is no FUNAUDIT, the report goes to the Model 204 audit trail. |
Parameters | A string that contains the parameters that are to be passed to Fast/Unload. This is an optional, name allowed, parameter; if it is not specified, no parameters are passed to Fast/Unload. |
AllMessages | A Boolean value. If True, all messages are sent to the Fast/Unload report destination specified by the Report argument. Informational messages ordinarily suppressed by the Fast/Unload User Language Interface are included by this setting.
This is an optional, name required, parameter, and it defaults to False. That is, many informational messages are suppressed from the report output by default. |
Asynch | A Boolean value:
This is an optional, name required, parameter, and it defaults to False. Note: |
Notify | A Boolean value:
|
MaxTime | A numeric value that indicates the maximum number of seconds after initiation of the request that the request is given to complete. If the request has not even started running in a Fast/Unload task, or if the task is running, but hasn't completed after the timeout period, the request is cancelled (resulting in a return code 32 from Fast/Unload).
A value of 0 for MaxTime means that the request will never timeout. This is an optional, name required, parameter, and it defaults to the setting of the FUNMAXT system parameter. Note: A request can timeout through no fault of its own if all the Fast/Unload tasks are taken up by other long-running requests. |
Usage notes
- Any errors in the method parameter list, or any environmental errors that would prevent the request from being run, result in the request being cancelled.
Example
In the following example, the FastUnload method uses Fast/Unload to do a PAI unload
to a Stringlist of all the records in file SIRFILED
,
and then it displays the Stringlist:
b %rs is object recordSet in file sirFiled %listi is object stringList %listo is object stringList %rc is float find records to %rs end find %listi = new text to %listi FOR EACH RECORD PUT '*' OUTPUT PAI END FOR end text %listo = new %rc = %rs:fastUnload(%listi, %listo, parameters='NEBUFF=10') %listo:print end
See also
- The Fast/Unload wiki pages.
- The FastUnloadTask function, which allows SOUL processing of the Fast/Unload output as it is created.