Converting Real to String in Spotfire client rounds to 2 decimal places

Converting Real to String in Spotfire client rounds to 2 decimal places

book

Article ID: KB0070238

calendar_today

Updated On:

Products Versions
TIBCO Cloud Spotfire All
Spotfire Desktop All

Description

When using the String() function to cast a Real column to a String column, only two decimals are included regardless of how many decimals are displayed under Data menu > Column Properties > Formatting.

For example, if a Real column called [Values] included a value for Pi of 3.14159265, using String([Values]) would output 3.14.

Issue/Introduction

When converting a Real column to String not all decimals are included

Environment

All

Resolution

To avoid the undesired rounding, use the Concatenate() function to convert the entire Real number to a String column when a space is added before the column. For example:
Concatenate(" ", [Values])
In the above example, Concatenate(" ", [Values]) will produce 3.14159265

Note: Make sure to set the formatting of the Real column to display the desired number of columns.
 

Additional Information

Doc: Text Functions: