website logo
Navigate through spaces
ChartHop documentation
⌘K
ChartHop Help Center
Getting around in ChartHop
ChartHop for Employees
Implementing ChartHop
ChartHop for Administrators
Carrot reference
ChartHop for Developers
Partners
Release notes
Resources
Docs powered by archbee 
website logo

money()

Converts a given value to datatype Money, including currency conversion.

Syntax

money(value[, currency])

  • value - the value to be evaluated by the function.
  • currency - (optional) the currency type of the returned Money value.
  • Return type: Money

Sample usage

money(10) returns $10 if USD is the primary currency.

Supported data types

Input type

Return type

Logic

Number

Money

If a Number value is passed, the amount will be returned as a Money value with the specified currency type (default: org.currency).

Money

Money

If a Money value is passed, the amount will be converted to the specified currency value if it is different from the original currency type.

Unsupported data types

Null

Unsupported data types return Null.



Updated 03 May 2023
Did this page help you?
Yes
No
PREVIOUS
mean()
NEXT
month()
Docs powered by archbee 
TABLE OF CONTENTS
Syntax
Sample usage
Supported data types