Send feedback on this topic.
Teradata.Client.Provider
Equals(TdDecimal,TdDecimal) Method
Example 



Teradata.Client.Provider Namespace > TdDecimal Structure > Equals Method : Equals(TdDecimal,TdDecimal) Method
A TdDecimal instance.
A TdDecimal instance.
Compares two TdDecimal instances to determine whether they are equal.
Syntax
'Declaration
 
Public Overloads Shared Function Equals( _
   ByVal left As TdDecimal, _
   ByVal right As TdDecimal _
) As Boolean
'Usage
 
Dim left As TdDecimal
Dim right As TdDecimal
Dim value As Boolean
 
value = TdDecimal.Equals(left, right)
public static bool Equals( 
   TdDecimal left,
   TdDecimal right
)
public:
static bool Equals( 
   TdDecimal left,
   TdDecimal right
) 

Parameters

left
A TdDecimal instance.
right
A TdDecimal instance.

Return Value

true if the left is equal to the right, false otherwise.

Return Value Description
true

left and right are TdDecimal.Null

-or-

left is equal to right.

false

left or right is Null

-or-

left is not equal to right.

Example
The following code example uses various comparison methods and operators.
// The M is used to indicate that the numeric literal is a System.Decimal
TdDecimal  large = new TdDecimal(32425643243167.43433M);
TdDecimal medium = new TdDecimal(89732.4543M);
 
// The following comparison methods and operators are equivalent
if (false == TdDecimal.Equals(large, medium) ||
    large != medium ||
    true == TdDecimal.NotEquals(large, medium) )
{
   Console.WriteLine("large does not equal medium");
}
Requirements

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

See Also

Reference

TdDecimal Structure
TdDecimal Members
Overload List