17.10 - Example: Querying for the Number of Months for One Date - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - SQL Date and Time Functions and Expressions

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Programming Reference
Publication ID
B035-1211-171K
Language
English (United States)

The following query:

SELECT MONTHS_BETWEEN(DATE'2008-09-25', DATE'2008-09-25');

returns the result 0.0 since date_timestamp_value1 and date_timestamp_value2 are both the same date.