'Usage Dim instance As TdParameter Dim value As T value = instance.GetValue(Of T)()
Type Parameters
- T
- The data type of the value to be returned.
Return Value
Returns the value of the parameter represented as a T type.
'Usage Dim instance As TdParameter Dim value As T value = instance.GetValue(Of T)()
Exception | Description |
---|---|
System.InvalidOperationException | The parameter is not an output parameter, type T is not a supported type for GetValue, or the internal TdDataReader is closed. |
System.InvalidCastException | This parameter type can not be cast to type T, or the output value is DBNull for a type that does not support nulls. |
System.OverflowException | The parameter value is too large to be cast to type T. |
System.FormatException | The parameter value is not in the correct format for type T. |
TdException | The .NET Data Provider detected an error. |
Int16 Int32 Int64 Decimal Double Single Byte Char Byte[] Char[] DateTime TimeSpan String Stream TextReader XmlReader DateTimeOffset Plus all Teradata provider specific types (TPST)
NOTE: In order to avoid a potential InvalidCastException call TdParameter.IsDBNull before calling this function. This is not required if T is a TPST since all TPST types support null values through their own IsNull() method.
LOB output parameters maintain their own state, which includes the position within the LOB. The data reader is not able to reset the position to the start of a LOB so you must only call one of the following Properties or Methods, one time:
Target Platforms: Windows 7, Windows 8, Windows 8.1, Windows 10, Windows Server 2008, Windows Server 2008 R2, Windows Server 2012, Windows Server 2012 R2