Gives you this:
SELECT 141/207
FROM dual

.681159420289855072463768115942028985507

----- Original Message -----
From: "John Stanley" <[EMAIL PROTECTED]>
To: "CF-Community" <[EMAIL PROTECTED]>
Sent: Tuesday, February 03, 2004 12:50 PM
Subject: RE: SOT....OK.....Way OT

> What does oracle do?
>
> -----Original Message-----
> From: Ben Braver [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, February 03, 2004 12:47 PM
> To: CF-Community
> Subject: Re:SOT....OK.....Way OT
>
>
> That floats my boat!
> well, it would if we used SQL2000 instead of Oracle :-)
>
> > SQL Question: SQL 2000
> >
> >Was gonna post this question, but found the answer, so maybe it will help
> >someone save some time
> >
> >The following:
> >    1.    Select 141/207 returns 0
> >    2.    Select Convert(float,141/207) returns .00000
> >
> >This is because SQL does the math first for the division, and apparently
> >treats anything less than one as zero, when the dividend and divisor are
> >integers.
> >
> >So you need to do this Select Convert(float,141)/Convert(float,207)
> >
> >Unless of course the data you are using is already not an integer.
> >
> >Have a happy day....
> >
> >John
> >
>   _____
>
>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to