Send feedback on this topic.
Teradata.Client.Provider
ToSingle Method (TdDecimal)



Teradata.Client.Provider Namespace > TdDecimal Structure : ToSingle Method
The TdDecimal that is to be converted to a single precision number.
Converts the value of the specified TdDecimal into the equivalent Single.
Syntax
'Declaration
 
Public Shared Function ToSingle( _
   ByVal input As TdDecimal _
) As Single
'Usage
 
Dim input As TdDecimal
Dim value As Single
 
value = TdDecimal.ToSingle(input)
public static float ToSingle( 
   TdDecimal input
)
public:
static float ToSingle( 
   TdDecimal input
) 

Parameters

input
The TdDecimal that is to be converted to a single precision number.

Return Value

A single precision value is returned that has the equivalent value as the specified TdDecimal.
Exceptions
ExceptionDescription
The value in the TdDecimal is Null.
Remarks
A rounding error can occur because a single precision floating point number contains fewer significant digits than a TdDecimal.
Requirements

Target Platforms: Windows 8.1, Windows 10, Windows Server 2012 R2, Windows Server 2016, Windows Server 2019

See Also

Reference

TdDecimal Structure
TdDecimal Members