Example
We have an Orders dataset with a Freight field.
In this example we will attempt to convert the real values in this field to string values representing currency. We will map the Freight field to the data field of the function transformation object.
We will also use a Variables object to specify an acceptable Microsoft.Net format for currency.
Where,
Format = C
In the output window, you can see that the provided data from the Freight field has been converted to a string representing currency.
Name
ToString
Syntax
ToString (Any data. String format)
Purpose
To convert a value into a string with a given format.
Description
Returns string representation of the specified value. Returns null if value is null or format is invalid.
Return Type
String
Parameters
Data [System.Object]
Format [System.String] – Output format of the value. This method accepts any Microsoft.Net format specification