Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: months_between function

Re: months_between function

From: Gene Plagge <gplagge_at_hotmail.com>
Date: Fri, 13 Nov 1998 06:17:32 -1000
Message-ID: <F42CB9DBDC42D211B39F00AA00AF32820233BCA2@Keiki.Hpu.Edu>


Eric,
months_between only works on Oracle dates. Either use the to_date function, or use Oracle default date format:

select months_between('01-FEB-96','15-NOV-96') from dual;

Eric St-pierre wrote in message <01be0e6d$a11d7900$7316320a_at_w00ai407>...
>I forgot... We use oracle 7.3.
>--
>Eric St-Pierre
>CPD5 Associate
>ericst_at_mediom.qc.ca
>
>Eric St-pierre <ericst_at_mediom.qc.ca> a écrit dans l'article
><01be0e6d$6dc4f100$7316320a_at_w00ai407>...
>> Does anybody knows where that query does not work :
>>
>> select months_between('1996-02-01','1996-11-15')
>> from dual;
>>
>> This Query return NULL. Is there a problem with the months_between
>function
>> ?
>>
>> Thanks.
>>
>> --
>> Eric St-Pierre
>> CPD5 Associate
>> ericst_at_mediom.qc.ca
>>
Received on Fri Nov 13 1998 - 10:17:32 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US