FORMAT_NUMBER

Description

FORMAT_NUMBER formats a number as a string with a configurable number of decimal places, decimal separator, and thousands separator. Useful for displaying monetary amounts or other numeric values in a locale-appropriate or house-style format.

Syntax

FORMAT_NUMBER(number, decimal_places?, decimal_sep?, thousands_sep?)

Returns: A formatted string representation of the number.

Example

FORMAT_NUMBER(1234567.891)

This returns '1,234,567.89'.

Example with custom separators

FORMAT_NUMBER(1234567.891, 2, ',', '.')

This returns '1.234.567,89' — useful for European locale formatting.

Example in context

p is Person
FORMAT_NUMBER(p.total_assets, 2, '.', "'")

Returns the total assets formatted as e.g. "1'234'567.89" for Swiss-style display.

Last updated

Was this helpful?