CLCSQRT CALCULATE SQUARE ROOT TAACLRX |
The Calculate Square Root command calculates the square root of a
numeric value that is greater than 0. The input value should be
passed as a *DEC (15 5) value which allows numbers such as 123 or
123.456 to be input. The return value must be specified as *DEC
LEN(15 5).
A typical set of commands would be:
DCL &RTNSQRT *DEC LEN(15 5)
.
CLCSQRT INPUT(nnn) RTNVAL(&RTNSQRT)
CLCSQRT escape messages you can monitor for
-------------------------------------------
TAA9891 The input value must be greater than 0
Escape messages from based on functions will be re-sent.
Command parameters *CMD
------------------
INPUT The input value to take the square root of. The
input value should be passed as a *DEC (15 5) value
which allows numbers such as 123 or 123.456 to be
input.
RTNSQRT The return square root value. It must be specified
as *DEC LEN(15 5).
Restrictions
------------
Because CLCSQRT returns a variable, the command may only be used in a
CL program.
Prerequisites
-------------
The following TAA Tools must be on your system:
SNDESCINF Send escape information
SNDESCMSG Send escape message
Implementation
--------------
None, the tool is ready to use.
Objects used by the tool
------------------------
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
CLCSQRT *CMD TAACLRX QATTCMD
TAACLRXC *PGM CLP TAACLRXC QATTCL
TAACLRXR *PGM RPG TAACLRXR QATTRPG
|
Added to TAA Productivity tools June 30, 2007