MONTHS_BETWEEN Assignment Help

Assignment Help: >> Scalar Functions - MONTHS_BETWEEN

MONTHS_BETWEEN

Syntax

MONTHS_BETWEEN(d1,d2)
It will return number of months among dates d1 and d2. The result is positive if d1 is later than d2; the result is negative if d1 is earlier than d2. The result is always an integer if d1 and d2 are either the similar days of the month or both last days of months; or else ORACLE calculates the fractional portion of the result based on a 31-day month and also considers the difference in time parts of d1 and d2.

Example

SELECT MONTHS_BETWEEN(sysdate,’10-JAN-00’) "Months" FROM DUAL;
Months
---------
10.829904

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd