Guys,
How we can set a strict affinity mode in sqlite3?
Thanks
On Tue, 2005-08-30 at 15:04 -0400, Ned Batchelder wrote:
> As near as I can tell, this line in printf.c (line 445):
>
> while( realvalue>10.0 && exp<=350 ){ realvalue *= 0.1; exp++; }
>
> should be:
>
> while( realvalue>=10.0 && exp<=350 ){ realvalue *= 0.1; exp++; }
>
Tha
One more thing: this seems to happen because realvalue is
9.9493, and rounder is 0.050003, and adding them
together produces exactly 10.000! Other platforms or libraries
may be producing slightly different values which ended up being a hair less
than 10 or a hai
I reproduced it here as well.
As near as I can tell, this line in printf.c (line 445):
while( realvalue>10.0 && exp<=350 ){ realvalue *= 0.1; exp++; }
should be:
while( realvalue>=10.0 && exp<=350 ){ realvalue *= 0.1; exp++; }
The comment at line 440 says it's trying to mak
It appears to be a problem with the sqlite3.exe itself and not the sqlite3
DLL. SELECT ROUND(9.95, 1); from the command-line util gives me :.0, but
executing the statement externally gives me 9.9
Robert
- Original Message -
From: "Bob Dankert" <[EMAIL PROTECTED]>
To:
Sent: Tuesday,
Using the sqlite.exe 3.2.5 binary off the website with WinXP SP2 here, I
get the ":.0" result (less the quotes). I have tried this on a couple
machines in the office here running similar environments.
Bob
Envision Information Technologies
Associate
[EMAIL PROTECTED]
v. 608.256.5680
f. 608.256.
On Tue, 2005-08-30 at 12:46 -0500, Bob Dankert wrote:
> According to that, it rounds to the nearest even number. Shouldn't 9.95
> go to 10 then, and 9.85 go to 9.8?
>
> After additional testing with SQLite 3.2.2, I have the following
> results:
>
> Round(9.95,1) -> 9.9*Rounded Down*
> Round
Do numbers with a final digit of five and
rounding precision greater than zero ever
round up?
Bob Dankert wrote:
According to that, it rounds to the nearest even number. Shouldn't 9.95
go to 10 then, and 9.85 go to 9.8?
After additional testing with SQLite 3.2.2, I have the following
results:
According to that, it rounds to the nearest even number. Shouldn't 9.95
go to 10 then, and 9.85 go to 9.8?
After additional testing with SQLite 3.2.2, I have the following
results:
Round(9.95,1) -> 9.9*Rounded Down*
Round(9.85,1) -> 9.8*Rounded Down*
Round(9.5,0) -> 10 *Rounded U
Here's some results on SQL Server 2000 starting with a value of -10 and
working my way up to 10 in .01 increments. Snipped for brevity.
The SQL:
set nocount on
drop table #temp
create table #temp (orig float(53), rounded float(53))
declare @num float(53)
SET @num = -10
WHILE @num < 10
BEGIN
Interesting...
Bankers' Rounding
http://blogs.msdn.com/ericlippert/archive/2003/09/26/53107.aspx
Brass Tilde wrote:
From: "Bob Dankert"
Using an older version which I compiled, I get 9.9, though it
seems it should round up to 10.0?
This may be dependent upon the math library linked into
> From: "Bob Dankert"
> Using an older version which I compiled, I get 9.9, though it
> seems it should round up to 10.0?
This may be dependent upon the math library linked into the application
by the compiler used to build SQLite. Some libraries appear to now be
using so-called "banking roundin
Hi,
On Windows XP testing for SQLite 3.2.5:
:.0 when using the sqlite3 executable downloaded
9.9 when running a program linked to an SQlite3 static library compiled by the
MinGW port of GCC 3.4.2
Eugene Wee
Edzard Pasma wrote:
I found a number where the ROUND () function goes wrong:
SQLite
I can reproduce this behavior using 3.2.5 compiled with MS VC++ 7.
3.2.2 didn't produce consistent behavior cross-platform when rounding
numbers that ended with .5, so yes, it should have rounded up to 10.0.
:)
-Tom
> -Original Message-
> From: Bob Dankert [mailto:[EMAIL PROTEC
2.8.15 gives 9.9
--Keith
On 8/30/05, Bob Dankert <[EMAIL PROTECTED]> wrote:
>
> Using the downloaded command-line tool for 3.2.5, I get the same :.0
> result. Using an older version which I compiled, I get 9.9, though it
> seems it should round up to 10.0?
>
> Bob
>
> Envision Information Tech
Using the downloaded command-line tool for 3.2.5, I get the same :.0
result. Using an older version which I compiled, I get 9.9, though it
seems it should round up to 10.0?
Bob
Envision Information Technologies
Associate
[EMAIL PROTECTED]
v. 608.256.5680
f. 608.256.3780
-Original Message-
Edzard Pasma wrote:
I found a number where the ROUND () function goes wrong:
SQLite version 3.2.5
Enter ".help" for instructions
sqlite> select round (9.95, 1);
:.0
I get 9.9 (running on Win98, compiled with MingW).
I found a number where the ROUND () function goes wrong:
SQLite version 3.2.5
Enter ".help" for instructions
sqlite> select round (9.95, 1);
:.0
Sorry, it must be that I have bad luck today
Edzard Pasma
_
Tired of spam and viruses? Ge
Hi Guys,
I am using sqlite 3.0.8 on LInux.
When I execute the following sql using 'sqlite3_get_table' api, I am getting
'internal SQLite implementation flaw' error. This used to work fine earlier.
select * from users where usrid='admin' and passwd='admin'
Any ideas??
Same is working fine in '
19 matches
Mail list logo