RE: [sqlite] database table is locked

2005-05-13 Thread Dan Kennedy
It's probably not a good idea, because it depends on some behaviour that is not specified, but I once used a trick like this to get good performance: CREATE TABLE abc(a, b); UPDATE abc SET b = user2(a, b) WHERE AND user1(a, b); SQLite loops through the rows where is true, and remembers those

RE: [sqlite] Convert and isnumeric function

2005-05-13 Thread Michael Evenson
Jay, I kindly beg to differ. I have a situation where a column can contain either a name (like Joe Blow) or a numeric link to another name (like 12345). If the column contains a numeric value then the link is followed otherwise just the name is used. I would normally just handle it in

RE: [sqlite] Convert and isnumeric function

2005-05-13 Thread Michael Evenson
Here is the isnumeric function. Don't forget to add the line to the sqlite3RegisterBuiltinFunctions function. { "isnumeric", 1, 0, SQLITE_UTF8,0, isnumericFunc}, I put it right after the abs function declartation /*

Re: [sqlite] Convert and isnumeric function

2005-05-13 Thread Jay Sprenkle
> All or any, > > Has anyone implemented these as built in functions in sqlite 3? If > not - I was thinking of doing it and submitting to the sqlite.org web site > for submission. The api converts data types for you. Isnumeric might be useful but since the database isn't strongly typed

[sqlite] Convert and isnumeric function

2005-05-13 Thread Michael Evenson
All or any, Has anyone implemented these as built in functions in sqlite 3? If not - I was thinking of doing it and submitting to the sqlite.org web site for submission. Mike

Re: [sqlite] nested functions in select

2005-05-13 Thread Kurt Welgehausen
> ... select count(distinct(something)) ... http://www.sqlite.org/omitted.html BTW, distinct is not a function. Regards

RE: [sqlite] database table is locked

2005-05-13 Thread Thomas Briggs
> No, that seems to work fine. I guess the table is locked for a > specific transaction, so you cannot have any problems with a lock held > by the very same transaction. > > > ie Below would return "database table is locked"? > > > > BEGIN TRANSACTION > > SELECT * from table1 WHERE col > x > >

RE: [sqlite] database table is locked

2005-05-13 Thread D. Richard Hipp
On Fri, 2005-05-13 at 15:16 +0100, Brandon, Nicholas wrote: > I think I might be getting confused on this subject as well. Does this mean > that SQLite 3.x can NOT process multiple inserts/updates within one > transaction if it is working on the same table? > > ie Below would return "database

Re: [sqlite] database table is locked

2005-05-13 Thread Thomas Steffen
On 5/13/05, Brandon, Nicholas <[EMAIL PROTECTED]> wrote: > > I think I might be getting confused on this subject as well. Does this mean > that SQLite 3.x can NOT process multiple inserts/updates within one > transaction if it is working on the same table? No, that seems to work fine. I guess

RE: [sqlite] database table is locked

2005-05-13 Thread Brandon, Nicholas
I think I might be getting confused on this subject as well. Does this mean that SQLite 3.x can NOT process multiple inserts/updates within one transaction if it is working on the same table? ie Below would return "database table is locked"? BEGIN TRANSACTION SELECT * from table1 WHERE col > x

RE: [sqlite] Does sqlite really support transaction?

2005-05-13 Thread John Buck
>Jay Sprenkle wrote: >The transaction doesn't seem any different than a snapshot of the >database that you can restore to. I just wondered why there were two >methods of doing the same thing. Only in a single user/single thread case are they the same thing. With Sqlite that might always be

[sqlite] Any interest on locking for 3.x in windows CE?

2005-05-13 Thread Nuno Lucas
Hello, I finally implemented locking on the Windows CE port for the 3.x version, and did it some time ago now. The problem is I need to test it and as I don't need to use it, have been delaying the making of the tests. I was thinking if anyone that would actually use it was interested of making

Re: [sqlite] request for additions to sqlite 3.xx

2005-05-13 Thread Nuno Lucas
[13-05-2005 9:31, Chmielewski Andrzej escreveu] comm Wiadomosc ta jest przeznaczona jedynie dla osoby lub podmiotu, ktory jest jej adresatem i moze zawierac poufne i/lub uprzywilejowane informacje. Zakazane jest

[sqlite] SQLite Java Wrapper?

2005-05-13 Thread majed chatti
I tried to use the SQLite Java Wrapper wich I download froh here http://www.ch-werner.de/javasqlite/ I extract it I do $./configure $make but I have this errors ./libtool gcc -I -o native/mkconst native/mkconst.c \ /usr/local/lib/libsqlite3.la gcc -I -o native/mkconst native/mkconst.c

RE: [sqlite] request for additions to sqlite 3.xx

2005-05-13 Thread Chmielewski Andrzej
comm Wiadomosc ta jest przeznaczona jedynie dla osoby lub podmiotu, ktory jest jej adresatem i moze zawierac poufne i/lub uprzywilejowane informacje. Zakazane jest jakiekolwiek przegladanie, przesylanie,

Re: [sqlite] Duplicate keys

2005-05-13 Thread Martin Engelschalk
Hi, SQL standard does not define the order of the duplicate rows and sqlite does not either. I would really not depend on a thing like this, even if the rows are in fact retrieved in the same order they were inserted (some DB systems I know of do this). If you need the rows retrieve Rows in a

RE: [sqlite] java class to connect to an sqlite DB

2005-05-13 Thread majed chatti
thank you but I'm sory I'm on linux. any one have a java class to connect to an an sqlite data base. Working on linux. thaks for help --- Steve O'Hara <[EMAIL PROTECTED]> a écrit : > > Assuming you're on Windows, try this for size. > Put the this DLL and the latest sqlite3.dll from the > web

[sqlite] Duplicate keys

2005-05-13 Thread Michael Knigge
Hi, is the order, in which rows with duplicate keys are retrieved, specified? For example: A table with two columns - the first is a Index. If I INSERT in the following order: C1 C2 - 3 1 1 1 1 2 1 1 1 3 2 1 If I now do a "SELECT * FROM Table ORDER BY C1;", is it guranteed that the