Send feedback on this topic.
Teradata.Client.Provider
RightDiff Method (TdPeriodTime)



Teradata.Client.Provider Namespace > TdPeriodTime Structure : RightDiff Method
The left TdPeriodTime operand.
The right TdPeriodTime operand.
The period that contains the portion from the ending bound of the left operand to the ending bound of the right when the operands overlap.
Syntax
'Declaration
 
Public Shared Function RightDiff( _
   ByVal left As TdPeriodTime, _
   ByVal right As TdPeriodTime _
) As TdPeriodTime
'Usage
 
Dim left As TdPeriodTime
Dim right As TdPeriodTime
Dim value As TdPeriodTime
 
value = TdPeriodTime.RightDiff(left, right)
public static TdPeriodTime RightDiff( 
   TdPeriodTime left,
   TdPeriodTime right
)
public:
static TdPeriodTime RightDiff( 
   TdPeriodTime left,
   TdPeriodTime right
) 

Parameters

left
The left TdPeriodTime operand.
right
The right TdPeriodTime operand.

Return Value

A TdPeriodTime is returned that contains the period that begins from the end of the left operand to the end of the right when the operands overlap.
Remarks

A TdPeriodTime.Null is returned under the following scenarios:

In the following examples the left and right operands are defined as (bL, eL) and (bR, eR), respectively.

Example Comments
            |------|------|-------|
            bL     bR     eL      eR
                          |=======|
            
Rdiff = (eL, eR)
            |------|-----|--------|
            bR     bL    eL       eR
                         |========|
            
Rdiff = (eL, eR)
            |-----|------|------|
            bL    bR     eR     eL
            

Rdiff = null

The left operand's ending bound is greater than the ending bound of the right operand.

            |-----|-------|------|
            bL    bR      eR     eL
            

Rdiff = null

The left operand's ending bound is greater than the ending bound of the right operand.

            |-------|-----|------|
            bL      eL    bR     eR
            

Rdiff = null

The left and right operands do not overlap.

            |---------|-----|--------|
            bR        eR    bL       eL
            

Rdiff = null

The left and right operands do not overlap.

            |----------|----------|
            bL         bR       eL eR
            

Rdiff = null

The ending bounds are equal. In other words, a period cannot be defined whose starting and ending bounds are equal.

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

TdPeriodTime Structure
TdPeriodTime Members