Part 4 Commands
STR (Convert character string; decimal)
Extension condition
(LD, A, O, AB, OB)
Input condition
(I/O, flag)
Output
(Output, flag)
Operand 1 Operand 2
Optional Optional STR
Column
number
Data CC
Copy to the column specified in operand 1 a decimal character string converted from the data
specified in operand 2.
The data will be adjusted to the length set by a SLEN command.
If the data exceeds the specified length, it will be cut off at the length set by a SLEN
command.
If the entire data has been converted within the length set by a SLEN command, the output
If the data specified in operand 2 is a 10-digit integer including eight or more valid digits,
conversion of the values in the eighth and subsequent digits will not be guaranteed (the
values through the seventh digits will be converted properly.)
Set a length consisting of five integer digits and three
decimal digits.
The following values will be set in columns 1 to 9:
1 2 3 4 5 6 7 8 9
1 2 3 . 0 0 0
Assign 987.6543 to variable 102.
SLEN 2.3 Set a length consisting of two integer digits and three
STR *1 *102 The following values will be set in columns 10 to 15:
10 11 12 13 14 15
8 7 . 6 5 4
Since the data is greater than the length, the value
obtained by rounding off 9 in the 100’s place, or 87, is set
in the integer part, while the value obtained by rounding 3
in the fourth decimal place, or 654, is set in the decimal
Commentaires sur ces manuels