SPELL_NUMBER
Converts a number into words
Usage
SPELL_NUMBER(number, [round_to])
Parameters
number |
(Required) The number to spell out |
round_to |
Numbers must first be rounded to avoid infinite decimals (0.33333…). This value is passed to ROUND(). Default is 10, max is 100. |
Examples
More information
Important note: DocuMold needs to know the language of the document. See the @LANGUAGE
action
documentation for more details. The examples above assumed language is set to English.
For decimal numbers, the function spells out the whole part and the decimal part separately, using the word “point” to indicate the decimal separator.
Reminders
A text containing digits is not handled as a number. To have an actual number:
- use the
@NUMBER_QUESTION
to set the variable - write a numeric value directly in the code without quotes, ex:
age >= 18
- use a function which converts to a number:
NUMBER(text_containing_numbers)
- use a function which returns a number:
FIND("world", "hello everybody")