Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: integer division
Daren Lee wrote:
>
> hi
>
> does anyone know how to force integer division?
>
> i'm subtracting 2 DATE types to get the number of
> days between them and then i need to divide by 7.
>
> e.g:
>
> to_char(date1,'j')-to_char(date2,'j')/7
>
> thanks
try:
(date1 - date2)/7
-- - Jim Yoshii ====================================================================== NOTICE TO BULK EMAILERS: Pursuant to US Code, Title 47, Chapter 5, Subchapter II, 227, any and all nonsolicited commercial e-mail sent to this address is subject to a download and archival fee in the amount of $500 US. E-Mailing denotes acceptance of these terms. ======================================================================Received on Tue Jul 01 1997 - 00:00:00 CDT