Send feedback on this topic.
Teradata.Client.Provider
CompareTo(Object) Method



Teradata.Client.Provider Namespace > TdPeriodTimestamp Structure > CompareTo Method : CompareTo(Object) Method
TdPeriodTimestamp instance to compare against.
Compares this instance to the specified TdPeriodTimestamp obj.
Syntax
'Declaration
 
Public Overloads Function CompareTo( _
   ByVal obj As Object _
) As Integer
'Usage
 
Dim instance As TdPeriodTimestamp
Dim obj As Object
Dim value As Integer
 
value = instance.CompareTo(obj)
public int CompareTo( 
   object obj
)
public:
int CompareTo( 
   Object^ obj
) 

Parameters

obj
TdPeriodTimestamp instance to compare against.

Return Value

The result of the comparison is returned as an integer.
Exceptions
ExceptionDescription
obj is not of type TdPeriodTimestamp
Remarks

The integer returned when this instance is compared to obj indicates the following:

Return Value Meaning
Less than zero

This instance is less than obj.

-or-

This instance is TdPeriodTimestamp.Null.


Comparison Algorithm

this.Begin < other.Begin OR (this.Begin == other.Begin AND this.End < other.End)

Zero

This instance is equal to obj.

-or-

This instance and obj are Null.


Comparison Algorithm

this.Begin == other.Begin AND this.End == other.End

Greater than zero

This instance is greater than obj.

-or-

obj is Null.


Comparison Algorithm

this.Begin > other.Begin OR (this.Begin == other.Begin AND this.End > other.End)

obj must be an instance of TdPeriodTimestamp type or null reference.

Requirements

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

See Also

Reference

TdPeriodTimestamp Structure
TdPeriodTimestamp Members
Overload List
CompareTo(TdPeriodTimestamp) Method