$FunForc: Difference between revisions

From m204wiki
Jump to navigation Jump to search
(Created page with "{{DISPLAYTITLE:$FunForc}} <span class="pageSubtitle"><section begin="desc" />Cancel running or waiting &FUNL. request<section end="desc" /></span> <p class="warning">Most Sirius...")
 
m (misc cleanup)
 
(35 intermediate revisions by 7 users not shown)
Line 1: Line 1:
{{DISPLAYTITLE:$FunForc}}
{{DISPLAYTITLE:$FunForc}}
<span class="pageSubtitle"><section begin="desc" />Cancel running or waiting &FUNL. request<section end="desc" /></span>
<span class="pageSubtitle">Cancel running or waiting [[Fast/Unload]] request</span>


<p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. The OO equivalent for the $FunForc function is [[to be entered]].</p>
This cancels a <var class="product">[[Fast/Unload]]</var> request that is either running or enqueued to run.


 
The <var>$FunForc</var> function accepts one argument and returns a numeric result.  
 
This cancels a ''[[Fast/Unload]]'' request which is either running or enqueued to run.
 
The $FunForc function accepts one argument and returns a numeric result.  


The only argument is a string that identifies the request number for the request to be cancelled. To cancel a request, a user must either have initiated the request or have system manager privileges. For example, the following code creates an asynchronous unload request, and then immediately cancels it:
The only argument is a string that identifies the request number for the request to be cancelled. To cancel a request, a user must either have initiated the request or have system manager privileges. For example, the following code creates an asynchronous unload request, and then immediately cancels it:
Line 18: Line 14:


==Syntax==
==Syntax==
<p class="syntax"><section begin="syntax" /> %RESULT = $FunForc(req_num)
<p class="syntax"><span class="term">%result</span> = <span class="literal">$FunForc</span>(<span class="term">req_num</span>)
<section end="syntax" /></p>
<p class="caption">$FunForc Function
</p>
<p class="caption">%RESULT is set either to 0, if the request number req_num was found and cancelled, or to an error code, if the request could not be found or cancelled.</p>
<p class="code">
5 - User does not have privilege to cancel request
6 - Request not found
</p>
<p class="caption">$FunForc Error Codes
</p>
</p>


<p>
<var class="term">%result</var> is set to either of these: </p>
<ul>
<li>0, if the request number <var class="term">req_num</var> was found and cancelled.</li>


$FunForc immediately DETACH'es a ''[[Fast/Unload]]'' task while $FunPurg allows the ''[[Fast/Unload]]'' task to do a "clean" termination. Indiscriminate use of $FunForc could result in certain resources (such as sort work files) being left "in use.&COQ. $FunForc should be used when $FunPurg cannot purge the request cleanly.<p>
<li>A return code, if the request could not be found or cancelled.</li>
</ul>


===Return codes===
<p class="code">5 - User does not have privilege to cancel request
6 - Request not found
</p>
==Usage notes==
<ul>
<ul>
<li><var>$FunForc</var> immediately DETACH'es a <var class="product">Fast/Unload</var> task, while <var>[[$FunPurg]]</var> allows the <var class="product">Fast/Unload</var> task to do a "clean" termination. Indiscriminate use of <var>$FunForc</var> could result in certain resources (such as sort work files) being left "in use".
Use <var>$FunForc</var> when <var>$FunPurg</var> cannot purge the request cleanly.</li>
</ul>


<li>&FUNULI
==Products authorizing {{PAGENAMEE}}==
 
<ul class="smallAndTightList">
<li>[[Fast/Unload SOUL Interface]]
</ul>
</ul>
   
   
</p>
<p class="caption">Products authorizing $FunForc
</p>
[[Category:$Functions|$FunForc]]
[[Category:$Functions|$FunForc]]
[[Category:Fast/Unload SOUL Interface]]

Latest revision as of 19:24, 16 March 2015

Cancel running or waiting Fast/Unload request

This cancels a Fast/Unload request that is either running or enqueued to run.

The $FunForc function accepts one argument and returns a numeric result.

The only argument is a string that identifies the request number for the request to be cancelled. To cancel a request, a user must either have initiated the request or have system manager privileges. For example, the following code creates an asynchronous unload request, and then immediately cancels it:

%RC = $FunLoad('DATA',..,'ASYNC') IF %RC GE 0 THEN %RC = $FunForc(%RC) END IF

Syntax

%result = $FunForc(req_num)

%result is set to either of these:

  • 0, if the request number req_num was found and cancelled.
  • A return code, if the request could not be found or cancelled.

Return codes

5 - User does not have privilege to cancel request 6 - Request not found

Usage notes

  • $FunForc immediately DETACH'es a Fast/Unload task, while $FunPurg allows the Fast/Unload task to do a "clean" termination. Indiscriminate use of $FunForc could result in certain resources (such as sort work files) being left "in use". Use $FunForc when $FunPurg cannot purge the request cleanly.

Products authorizing $FunForc