Skip Navigation
Expand
Formatting an integer field to display as currency
Answer ID 2430   |   Last Review Date 09/26/2018

When I include an integer custom field in a report, how can I format the field to display as currency?

Environment:

Analytics

Resolution:

Within a report, the make_currency function can be used to convert an integer type database field to a currency value. For example, the format below converts the field into US dollars:

make_currency(1, 'USD') * tablename.fieldname

where tablename.fieldname is the specific table and field of interest from your site.

You could also report the integer in cents instead of dollars, if you wish, using the example below:

make_currency(0.01,'USD') * tablename.fieldname