On Sat, 9 Jun 2007, Joe Wilson wrote:
CREATE TABLE t(b blob);
INSERT INTO "t" VALUES(X'ABCD');
select quote(b) from t;
X'ABCD'
Thanks, Joe. I am just wondering why this 'quote' is not the default
behavior on binary columns when the 'sqlite3' tool is used.
Best regards
Guido
---
Hi All,
I am running sqlite version 3.2.8, on a windriver linux, on a ppc
platform.
It is linked to PHP 5.1.4, where I have scripts that access the database
(both sets and gets). Recently I have been experimenting with
simultanious accesses to the sqlite database (meaning mutliple clients
request
Hello Scott Hess,
>I've lined up some time to work on fts, again, which means fts3. One
>thing I'd like to include would be to order doclists by some baked-in
>ranking. The idea is to sort to most important items to the front of
>the list, and then you can do queries which limit the number of hi
Folks.
I have just started learning about Full Text search in SQlite, and I
have some questions
1) With the Amalgamated Sqlite, I guess to enable FTS I just #define
SQLITE_ENABLE_FTS2 at the start of sqlite3.c
Is there anything else I have to do to switch it on ?
2) If I want to do a full
The integrated round-function works well so far,
especially because it does "bankers rounding".
Tough it seems to have a little bug, wich is probably simple to fix.
Try...
select round(0.94, 1) -> gives 0.9, wich is correct
select round(0.96, 1) -> gives 1, wich is correct too
but...
select roun
On 6/10/07, Ralf Junker <[EMAIL PROTECTED]> wrote:
Hello Scott Hess,
>I've lined up some time to work on fts, again, which means fts3. One
>thing I'd like to include would be to order doclists by some baked-in
>ranking. The idea is to sort to most important items to the front of
>the list, and
You're crashing in free(), which means your heap is corrupted.
The cause of the corruption could be from anywhere - and not
necessarily sqlite. It might be the victim of a previously corrupted
heap. Try running your program through a memory checker like valgrind
to see what it turns up.
Also tes
--- Guido Ostkamp <[EMAIL PROTECTED]> wrote:
> On Sat, 9 Jun 2007, Joe Wilson wrote:
> > CREATE TABLE t(b blob);
> > INSERT INTO "t" VALUES(X'ABCD');
> > select quote(b) from t;
> > X'ABCD'
>
> Thanks, Joe. I am just wondering why this 'quote' is not the default
> behavior on binary columns when
Olaf Schmidt <[EMAIL PROTECTED]> wrote:
> The integrated round-function works well so far,
> especially because it does "bankers rounding".
> Tough it seems to have a little bug, wich is probably simple to fix.
>
> Try...
> select round(0.94, 1) -> gives 0.9, wich is correct
> select round(0.96, 1
Olaf Schmidt <[EMAIL PROTECTED]> wrote:
> The integrated round-function works well so far,
> especially because it does "bankers rounding".
> Tough it seems to have a little bug, wich is probably simple to fix.
>
> Try...
> select round(0.94, 1) -> gives 0.9, wich is correct
> select round(0.96, 1
Hi drh,
> http://www.sqlite.org/faq.html#q18
Not so easy I think (I'm well aware of rounding-problems
regarding the IEEE-Float-Formats, etc.).
Bankers rounding aside at the moment.
select round(0.95, 1)
gives 0 - not 0.9 (in case rounding down) and
also not 1.0 (in case rounding up)
Funny th
On 6/10/07, Olaf Schmidt <[EMAIL PROTECTED]> wrote:
Hi drh,
> http://www.sqlite.org/faq.html#q18
Not so easy I think (I'm well aware of rounding-problems
regarding the IEEE-Float-Formats, etc.).
Bankers rounding aside at the moment.
select round(0.95, 1)
0.9
select round(9.95, 1)
9.9
I recently upgraded my server from RHEL 4 to RHEL 5 and one of the
changes is the PHP interface to sqlite changed to be exclusively through
PHP's PDO functions.
I converted my databases to sqlite3 successfully but I'm having no end
of troubles getting my PHP scripts to be able to perform que
> > select round(0.95, 1)
> 0.9
> > select round(9.95, 1)
> 9.9
> > select round(0.995, 2)
> 0.99
> > select round(9.995, 2)
> 9.99
> (3.3.17 here)
As it should be, hmm.
On what OS have you tested?
If on windows, was it a GCC-compile or a MS-VC-compile?
Olaf
--
View this message in context:
On 6/10/07, Olaf Schmidt <[EMAIL PROTECTED]> wrote:
> > select round(0.95, 1)
> 0.9
> > select round(9.95, 1)
> 9.9
> > select round(0.995, 2)
> 0.99
> > select round(9.995, 2)
> 9.99
> (3.3.17 here)
As it should be, hmm.
On what OS have you tested?
If on windows, was it a GCC-compile or a MS-VC
On Windows XP:
Did select round(0.95, 1) with your VB wrapper, gives 0
Same in the free SQLite2006 Pro (from OsenXPSuite) and same result.
RBS
-Original Message-
From: Olaf Schmidt [mailto:[EMAIL PROTECTED]
Sent: 10 June 2007 19:35
To: sqlite-users@sqlite.org
Subject: Re: [sqlite] error
Thanks to RBS and Alberto for testing...
So it seems the problem is somehow Windows-related
(maybe the VC-Compiler).
Think I'll override the Round-Function in my wrapper.
Regards,
Olaf
--
View this message in context:
http://www.nabble.com/error-in-round-function--tf3897765.html#a11052069
Se
Olaf Schmidt <[EMAIL PROTECTED]> wrote:
>
> select round(0.95, 1)
> gives 0 - not 0.9 (in case rounding down) and
> also not 1.0 (in case rounding up)
>
I can reproduce the problem by running sqlite3.exe on
windows. But I cannot explain it.
The problem occurs in printf.c on line 454:
if
> $sql = "SELECT count(*) FROM feedback";
> $result = $handle->query($sql);
> echo "rows = " . $result->rowCount() . "\n";
I've never used PHP, but just for kicks, to eliminate
the database from the equation, try:
$sql = "SELECT 123 AS abc;";
and see what happens.
--- Olaf Schmidt <[EMAIL PROTECTED]> wrote:
> On what OS have you tested?
> If on windows, was it a GCC-compile or a MS-VC-compile?
Running the GCC cross-compiled sqlite3.exe from
http://www.sqlite.org/sqlite-3_3_17.zip on Windows
(well, wine on Linux):
SQLite version 3.3.17
Enter ".help" f
Just checked my code and luckily I don't round in SQLite.
I suppose an easy work-around for now would be to do something like:
Select round(field + 0.001, 1) as it will be unlikely
you are dealing with 0.949
RBS
-Original Message-
From: Olaf Schmidt [mailto:[EMAIL
--- Joe Wilson <[EMAIL PROTECTED]> wrote:
> --- Olaf Schmidt <[EMAIL PROTECTED]> wrote:
> > On what OS have you tested?
> > If on windows, was it a GCC-compile or a MS-VC-compile?
>
> Running the GCC cross-compiled sqlite3.exe from
> http://www.sqlite.org/sqlite-3_3_17.zip on Windows
> (well, wi
--- [EMAIL PROTECTED] wrote:
> Going into this statement on both Linux and Windows,
> the exact same values are in realvalue and in rounder:
>
>realvalue: 0xf000 0.94995559107901499373838
>rounder:0x3faa 0.0500030
>
Well I basically did the following, but not sure it's optimal:
1) Took 3.3.17 amalgamation
2) Took shell.c from 3.3.17 full distribution, and made a target that
just uses sqlite3.c and shell.c to get the command line tool
3) Took whatever I had in my old makefile for compile flags and added
them f
On Sun, 2007-06-10 at 16:08 -0700, Brett Keating wrote:
> Well I basically did the following, but not sure it's optimal:
>
> 1) Took 3.3.17 amalgamation
> 2) Took shell.c from 3.3.17 full distribution, and made a target that
> just uses sqlite3.c and shell.c to get the command line tool
> 3) Took
25 matches
Mail list logo