RE: T-SQL division drops the decimal?

2003-08-01 Thread Kevin Webb
; 0 = 1/2 / 2 1/4 = 1/2 / 2.0 Kevin Webb -Original Message- From: Bill Grover [mailto:[EMAIL PROTECTED] Sent: Friday, August 01, 2003 6:08 AM To: CF-Talk Subject: RE: T-SQL division drops the decimal? Joshua, I bump into this all the time. You said it is a numeric field but what is the de

RE: T-SQL division drops the decimal?

2003-08-01 Thread Bill Grover
dissemination, distribution or copying is strictly prohibited. If you > have received this e-mail in error please delete it immediately and > advise us by return e-mail to > [EMAIL PROTECTED] > ********** > ** > * > > > -Ori

RE: T-SQL division drops the decimal?

2003-07-31 Thread Gaulin, Mark
ints/2.0 Since "2.0" looks like a float it will return a float. Mark -Original Message- From: Joshua Miller [mailto:[EMAIL PROTECTED] Sent: Thursday, July 31, 2003 12:04 PM To: CF-Talk Subject: RE: T-SQL division drops the decimal? Thanks all for the help, this is wha

RE: T-SQL division drops the decimal?

2003-07-31 Thread Joshua Miller
PROTECTED] * -Original Message- From: Paul Hastings [mailto:[EMAIL PROTECTED] Sent: Thursday, July 31, 2003 11:53 AM To: CF-Talk Subject: Re: T-SQL division drops the decimal? > I have a query that takes a value from the database and

RE: T-SQL division drops the decimal?

2003-07-31 Thread Joshua Miller
-Original Message- From: Craig Dudley [mailto:[EMAIL PROTECTED] Sent: Thursday, July 31, 2003 11:21 AM To: CF-Talk Subject: RE: T-SQL division drops the decimal? Silly question, but what datatype is the column which holds your result? Not forgotten about it and left it as an int have you? Ev

Re: T-SQL division drops the decimal?

2003-07-31 Thread Paul Hastings
> I have a query that takes a value from the database and divides by 2 and > inserts that value into another table, however SQL Server (T-SQL) drops > the decimal place, so 1/2 of 1 is 0 according to T-SQL. you're telling sql server to divide 2 int, it returns what you asked of it, an int. i alway

RE: T-SQL division drops the decimal?

2003-07-31 Thread DURETTE, STEVEN J (AIT)
:15 AM To: CF-Talk Subject: T-SQL division drops the decimal? How do others on the list deal with this? I have a query that takes a value from the database and divides by 2 and inserts that value into another table, however SQL Server (T-SQL) drops the decimal place, so 1/2 of 1 is 0 according to

RE: T-SQL division drops the decimal?

2003-07-31 Thread Adrian Lynch
Would it be because it's an integer? You may need to use CAST() or CONVERT(). Ade -Original Message- From: Joshua Miller [mailto:[EMAIL PROTECTED] Sent: 31 July 2003 16:15 To: CF-Talk Subject: T-SQL division drops the decimal? How do others on the list deal with this? I have a

RE: T-SQL division drops the decimal?

2003-07-31 Thread A.Little
rom: Joshua Miller [mailto:[EMAIL PROTECTED] > Sent: 31 July 2003 16:15 > To: CF-Talk > Subject: T-SQL division drops the decimal? > > > How do others on the list deal with this? > > I have a query that takes a value from the database and > divides by 2 and > inser

RE: T-SQL division drops the decimal?

2003-07-31 Thread Craig Dudley
16:15 To: CF-Talk Subject: T-SQL division drops the decimal? How do others on the list deal with this? I have a query that takes a value from the database and divides by 2 and inserts that value into another table, however SQL Server (T-SQL) drops the decimal place, so 1/2 of 1 is 0 according

RE: T-SQL division drops the decimal?

2003-07-31 Thread Bryan F. Hogan
It's the datatype of the column your holding your information in. Check the Docs for the correct datatype. -Original Message- From: Joshua Miller [mailto:[EMAIL PROTECTED] Sent: Thursday, July 31, 2003 11:15 AM To: CF-Talk Subject: T-SQL division drops the decimal? How do others o

T-SQL division drops the decimal?

2003-07-31 Thread Joshua Miller
How do others on the list deal with this? I have a query that takes a value from the database and divides by 2 and inserts that value into another table, however SQL Server (T-SQL) drops the decimal place, so 1/2 of 1 is 0 according to T-SQL. Any idea how to overcome this? That seems really odd