Number Formatting with Comma Separator inside Parameter Calculation

Version 8

    Description:  When using parameters to swap measures, we lose our default number formatting for those measures.  This simple workbook demonstrates one way to do some basic number formatting, including adding comma separators for dollar amounts, inside a calculation leveraged by a parameter.  This question comes up often on the General Forum, so I thought posting an example here might be beneficial.


    When downloading this workbook, the key bit is the calculated field named "Parameter Calc", which uses string manipulation to format the dollar amounts that result from the parameter selection.


    The calculation used will work for dollar amounts up to 100 trillion dollars, I believe. I got some help on this one, originally, and cannot recall who provided that help.

    NOTE: In order to make this work with chart types other than crosstabs/text, you would keep a numerical version of the parametrized value in play on the Columns/Rows/Color/etc shelves, while using the String version on the Label/Text shelf only.  For example, if creating a heat map, you would use the numerical version for your Axes/Coloring, but would place the String version on the Label shelf only. 




    Tableau Version: 8.0.4

    Original Author: Matt Lutton