Send feedback on this topic.
Teradata.Client.Provider
Subtract(TdIntervalYearToMonth) Method



Teradata.Client.Provider Namespace > TdDate Structure > Subtract Method : Subtract(TdIntervalYearToMonth) Method
A TdIntervalYearToMonth that will be subtracted from this instance of TdDate.
Subtracts the specified TdIntervalYearToMonth from this instance of TdDate.
Syntax
'Declaration
 
Public Overloads Function Subtract( _
   ByVal interval As TdIntervalYearToMonth _
) As TdDate
'Usage
 
Dim instance As TdDate
Dim interval As TdIntervalYearToMonth
Dim value As TdDate
 
value = instance.Subtract(interval)
public TdDate Subtract( 
   TdIntervalYearToMonth interval
)
public:
TdDate Subtract( 
   TdIntervalYearToMonth interval
) 

Parameters

interval
A TdIntervalYearToMonth that will be subtracted from this instance of TdDate.

Return Value

A TdDate is returned that is the result of subtracting the TdIntervalYearToMonth from this instance of TdDate.
Exceptions
ExceptionDescription
Unable to subtract the TdIntervalYearToMonth from this instance of TdDate.
Remarks

If the interval or this instance is Null a TdDate.Null will be returned.

The interval interval will be subtracted from TdDate. For example, if the date is "2007-10-04" and the interval is "10-03" (10 years, 3 months) the operation will result in "1997-07-04".

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

TdDate Structure
TdDate Members
Overload List