Write a query to Calculate the month difference
SELECT months_between (DOB,SYSDATE) FROM PSTUDENT;
Output :
MONTHS_BETWEEN(DOB,SYSDATE)
-169.3677
-174.658
-166.1741
-175.2064
-206.2064
-205.2064
-165.1741
SELECT months_between ('1-JAN-2003','1-JAN-2002') FROM dual;
Output :
MONTHS_BETWEEN('1-JAN-2003','1-JAN-2002')
12