Send feedback on this topic.
Teradata.Client.Provider
Parse(String) Method



Teradata.Client.Provider Namespace > TdIntervalSecond Structure : Parse(String) Method
A string to be converted into a TdIntervalSecond.
The specified string is converted into an equivalent TdIntervalSecond.
The specified string is converted into an equivalent TdIntervalSecond interval.
Syntax
'Declaration
 
Public Shared Function Parse( _
   ByVal value As String _
) As TdIntervalSecond
'Usage
 
Dim value As String
Dim value As TdIntervalSecond
 
value = TdIntervalSecond.Parse(value)
public static TdIntervalSecond Parse( 
   string value
)
public:
static TdIntervalSecond Parse( 
   String^ value
) 

Parameters

value
A string to be converted into a TdIntervalSecond.

Return Value

A TdIntervalSecond is returned that is equivalent to the TdIntervalSecond contained in the input string.
Exceptions
ExceptionDescription
value cannot be converted into a TdIntervalSecond interval.
value is a null reference.
The resultant operation returns a value greater than the TdIntervalSecond.MaxValue or less than the TdIntervalSecond.MinValue.
Remarks

This method supports the following string formats:

String Format Description
G

General interval format.

[sign][seconds].[ffffff]

L

SQL literal format. This string may be used in a SQL statement.

INTERVAL [sign]'[seconds].[ffffff]' SECOND

Below is the description of each format item.

Format Item Description
sign Optional - . Defaults as space character (+).
seconds Required number of seconds (one to four digits in length).
ffffff Optionally the number of fractional seconds (0 to 6 digits in length).

Cultural settings are not supported.

While parsing the value the TdIntervalSecond.Precision will be set to the number of digits contained within the seconds component. The TdIntervalSecond.Scale will be set to the number of digits in the fractional seconds component (digits that are to the right of the decimal point).

For example a value of "40.1234" will contain a precision of 2 and a scale of 4.

Requirements

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

See Also

Reference

TdIntervalSecond Structure
TdIntervalSecond Members