[sqlite] how to compile DBD::SQLite with the latest source and FTS3

2008-02-18 Thread P Kishor
http://www.sqlite.org/cvstrac/wiki?p=CompilingFtsThree works for me. -- Puneet Kishor http://punkish.eidesis.org/ Nelson Institute for Environmental Studies http://www.nelson.wisc.edu/ Open Source Geospatial Foundation (OSGeo) http://www.osgeo.org/

Re: [sqlite] fts3 complains no column named row_id

2008-02-18 Thread Scott Hess
On Mon, Feb 18, 2008 at 9:48 PM, P Kishor <[EMAIL PROTECTED]> wrote: > I get the error -- > > table fts_article has no column named row_id > > Needless to say, this didn't happen with fts2. Any guidance would be > appreciated. Are you sure? fts2 didn't have row_id, either. In either case,

[sqlite] fts3 complains no column named row_id

2008-02-18 Thread P Kishor
I am following the fts2 instructions in fts3. Assuming a table CREATE TABLE article (article_id INTEGER PRIMARY KEY, article_name, article_text); I created CREATE VIRTUAL TABLE fts_article USING fts3 (article_name, article_text); But when I try to INSERT INTO fts_article (row_id,

Re: [sqlite] Can more than one user connect to an in-memory database?

2008-02-18 Thread Brian Smith
Scott Chapman wrote: > Can more than one user connect to an in-memory database? > I don't see how. Any clues? If you have a memory filesystem (e.g. /dev/shm on Linux), you can just create the database within that filesystem, and it will be "in-memory". - Brian

Re: [sqlite] Outer join between two tables?

2008-02-18 Thread Gilles
At 19:37 18/02/2008 -0500, Igor Tandetnik wrote: >What makes you feel the above is a non-standard solution? Or perhaps you >mean it is, in your opinion, sub-standard? I didn't say it was, but in books on SQL, they usually talk about joints, hence my wondering if this were a more usual way of

Re: [sqlite] Outer join between two tables?

2008-02-18 Thread Igor Tandetnik
"Gilles Ganault" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Mon, 18 Feb 2008 15:03:27 -0500, "Igor Tandetnik" > <[EMAIL PROTECTED]> wrote: >> where phones_contact_tel not in (select tel from contacts) > > Thanks, it worked: > > SELECT * FROM phones WHERE phones_tel NOT IN

Re: [sqlite] Outer join between two tables?

2008-02-18 Thread Gilles Ganault
On Mon, 18 Feb 2008 15:03:27 -0500, "Igor Tandetnik" <[EMAIL PROTECTED]> wrote: >where phones_contact_tel not in (select tel from contacts) Thanks, it worked: SELECT * FROM phones WHERE phones_tel NOT IN (SELECT contacts_phones_tel FROM contacts); Out of curiosity, isn't the standard solution

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Sam Carleton
On Feb 18, 2008 11:33 AM, Scott Baker <[EMAIL PROTECTED]> wrote: > > The less database hits you have to do, the faster your code will be. > Getting all the data into a PHP data structure should be the way to go. After reading all the replies, I have to agree with Scott for my particular

Re: [sqlite] Can more than one user connect to an in-memory database?

2008-02-18 Thread Fin Springs
> Subject: [sqlite] Can more than one user connect to an in-memory database? > I don't see how. Any clues? You could share the sqlite3* handle from the process that opens that in-memory database, through some mechanism of your own. Since all your users would be using the same connection, you

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread John Stanton
Sqlite uses cacheing. I would suggest not storing large amounts of data in PHP arrays. It is buffer shadowing. Ideally with Sqlite you would use a cursor (the sqlite3_step logic) and pick up rows as you need them from the Sqlite cache. Digging a string of holes and filling them in is a

[sqlite] Can more than one user connect to an in-memory database?

2008-02-18 Thread Scott Chapman
I don't see how. Any clues? Thanks! Scott ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] SQLite Like Query Optimization

2008-02-18 Thread drh
"Kalyani Phadke" <[EMAIL PROTECTED]> wrote: > I have not recompiled sqlite 3 before. I am having trouble to find > documentation. > > Could anyone pls tell me how can I compile SQLite3 source code on > windows xp machine. Do I need to download FTS3 files ? Where can I find > those files? How can

Re: [sqlite] SQLite Like Query Optimization

2008-02-18 Thread P Kishor
On 2/18/08, Kalyani Phadke <[EMAIL PROTECTED]> wrote: > I have not recompiled sqlite 3 before. I am having trouble to find > documentation. > > Could anyone pls tell me how can I compile SQLite3 source code http://www.sqlite.org/cvstrac/wiki?p=CompilingFts > windows xp machine. no idea about

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Zbigniew Baniewski
On Mon, Feb 18, 2008 at 08:33:49AM -0800, Scott Baker wrote: > The less database hits you have to do, the faster your code will be. > Getting all the data into a PHP data structure should be the way to go. But, if one really is "loading all the data into memory at once" (just "SELECT * FROM

Re: [sqlite] SQLite Like Query Optimization

2008-02-18 Thread Kalyani Phadke
I have not recompiled sqlite 3 before. I am having trouble to find documentation. Could anyone pls tell me how can I compile SQLite3 source code on windows xp machine. Do I need to download FTS3 files ? Where can I find those files? How can I add this extension to my sqlite??? Thanks

Re: [sqlite] Outer join between two tables?

2008-02-18 Thread Igor Tandetnik
"Gilles Ganault" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Since the syntax "WHERE phones_contact_tel not in contacts;" doesn't > seem to exist But this does: where phones_contact_tel not in (select tel from contacts) Igor Tandetnik

Re: [sqlite] SQLite Like Query Optimization

2008-02-18 Thread P Kishor
On 2/18/08, Kalyani Phadke <[EMAIL PROTECTED]> wrote: > I am trying to use FTS3 with SQlite3 . Do I need to recompile SQlite3 > to enable FTS3? yes. > > From the command prompt I tried the following things > > Sqlite> .load libfts3.dll > Unable to open shared library libfts3.dll > Sqlite>select

Re: [sqlite] Counting rows in multiple tables and joining on an index

2008-02-18 Thread Trey Mack
create table t1 (rpsIndex INTEGER); create table t2 (rpsIndex INTEGER); create table t3 (rpsIndex INTEGER); insert into t1 values (1); insert into t1 values (1); insert into t1 values (2); insert into t2 values (1); insert into t2 values (2); insert into t2 values (3); insert into t3 values (3);

Re: [sqlite] Sqlite Version 3.2.2

2008-02-18 Thread jose isaias cabrera
Walt, I am doing it with 10 users, right now... However, if you read Dr. Hipp's reply, he is correct and that is the way to go. I will be doing what Dr. Hipp said in a few months. josé - Original Message - From: "Walt" <[EMAIL PROTECTED]> To: Sent:

Re: [sqlite] Sqlite Version 3.2.2

2008-02-18 Thread drh
"Walt" <[EMAIL PROTECTED]> wrote: > Is it feasible to a DataBase on one computer and have multiple > users on a LAN accessing the DataBase at the same time? > This can be made to work. But you will probably be much happier with a client/server database such as MySQL or PostgreSQL. They are

[sqlite] Sqlite Version 3.2.2

2008-02-18 Thread Walt
Is it feasible to a DataBase on one computer and have multiple users on a LAN accessing the DataBase at the same time? Thanks for your input Walt Mc Whirter ___ sqlite-users mailing list sqlite-users@sqlite.org

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Kees Nuyt
On Mon, 18 Feb 2008 11:25:16 -0500, you wrote: >I am new to SQLite and databases, so I am stil learning how to >optimize their use... > >I am working on a "shopping cart" type of feature, it is actually a >favorites feature for a system that displays images in multiple >galleries. There is a

[sqlite] Counting rows in multiple tables and joining on an index

2008-02-18 Thread jrpfinch
I have three tables, each of which has the column rpsIndex. This column is not a unique index/primary key. I would like to count the number of times each rpsIndex appears in all three tables. E.g. Table1 rpsIndex=1 rpsIndex=1 rpsIndex=2 Table2 rpsIndex=1 rpsIndex=2 rpsIndex=3 Table3 rpsIndex=3

Re: [sqlite] SQLite Like Query Optimization

2008-02-18 Thread P Kishor
On 2/18/08, Kalyani Phadke <[EMAIL PROTECTED]> wrote: > > Suppose User typed 'test' in search text box, I would like to search the > 'test' string in all the coulmns ... I do not want exact match.. The > columns could contain strings like 'tester' or 'tested' . I should be > able to get these

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Scott Baker
Michael Hooker wrote: > This is an issue which interests me too. The answer Scott gives makes > absolute sense to me, but all the PHP/MySQL books I've seen (and MySQL can't > be that different from Sqlite3 in this respect) seem to go the way of a new > query to the database every time a

Re: [sqlite] SQLite Like Query Optimization

2008-02-18 Thread Kalyani Phadke
Suppose User typed 'test' in search text box, I would like to search the 'test' string in all the coulmns ... I do not want exact match.. The columns could contain strings like 'tester' or 'tested' . I should be able to get these records as well.. Hope I am clear explaining what I want..

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Michael Hooker
This is an issue which interests me too. The answer Scott gives makes absolute sense to me, but all the PHP/MySQL books I've seen (and MySQL can't be that different from Sqlite3 in this respect) seem to go the way of a new query to the database every time a different set of data is needed,

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Paul Smith
At 16:25 18/02/2008, you wrote: >I am new to SQLite and databases, so I am stil learning how to >optimize their use... > >I am working on a "shopping cart" type of feature, it is actually a >favorites feature for a system that displays images in multiple >galleries. There is a SQLite table that

Re: [sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Scott Baker
Sam Carleton wrote: > I am new to SQLite and databases, so I am stil learning how to > optimize their use... > > I am working on a "shopping cart" type of feature, it is actually a > favorites feature for a system that displays images in multiple > galleries. There is a SQLite table that

[sqlite] which is faster, PHP or SQLite?

2008-02-18 Thread Sam Carleton
I am new to SQLite and databases, so I am stil learning how to optimize their use... I am working on a "shopping cart" type of feature, it is actually a favorites feature for a system that displays images in multiple galleries. There is a SQLite table that contains the user_id, gallery_id, and

Re: [sqlite] How to compile SQLite for Windows 32bit & 64bit?

2008-02-18 Thread Brad House
> Please Help > > Is there a good tutorial that shows how to compile SQLite for both > Windows 32 bit & 64bit? > > If ICU is required then I need the files to be statically linked rather > than having any external dependencies. > > Anyone know of a good tutorial for building both a 32bit

Re: [sqlite] PRIMARY KEY? Date and time datatypes?

2008-02-18 Thread Gilles Ganault
On Mon, 18 Feb 2008 12:32:55 +, [EMAIL PROTECTED] wrote: >The AUTOINCREMENT keyword prevents an primary key from being >reused even after it is deleted. Thanks for the clarification. ___ sqlite-users mailing list sqlite-users@sqlite.org

Re: [sqlite] PRIMARY KEY? Date and time datatypes?

2008-02-18 Thread Gilles Ganault
On Mon, 18 Feb 2008 23:31:32 +1100, BareFeet <[EMAIL PROTECTED]> wrote: >I can create a view to display the date in my localtime: Thanks much for the example. ___ sqlite-users mailing list sqlite-users@sqlite.org

[sqlite] How to compile SQLite for Windows 32bit & 64bit?

2008-02-18 Thread Jim Harkins
Please Help Is there a good tutorial that shows how to compile SQLite for both Windows 32 bit & 64bit? If ICU is required then I need the files to be statically linked rather than having any external dependencies. Anyone know of a good tutorial for building both a 32bit & 64bit DLL with

[sqlite] Outer join between two tables?

2008-02-18 Thread Gilles Ganault
Hello I have two tables: - Phones, which has two columns: Tel and Name. A customer may have more than one number - Contacts, which has the expected colums (address, e-mail, etc.), and, since phone numbers are unique, uses the main (or only) number in Phones as primary key. IOW, to find a

Re: [sqlite] PRIMARY KEY? Date and time datatypes?

2008-02-18 Thread drh
Gilles Ganault <[EMAIL PROTECTED]> wrote: > On Sat, 16 Feb 2008 11:29:29 +1100, BareFeet > <[EMAIL PROTECTED]> wrote: > > If you designate an integer column as also being the primary key, > > then SQLite will auto assign its value incrementally each time > > you insert a new row, unless you

Re: [sqlite] PRIMARY KEY? Date and time datatypes?

2008-02-18 Thread BareFeet
Hi Gilles, >> If you designate an integer column as also being the primary key, >> then SQLite will auto assign its value incrementally each time you >> insert a new row, unless you assign a value explicitly. > > In this case, why do we need to use "PRIMARY KEY AUTOINCREMENT"? Adding

Re: [sqlite] PRIMARY KEY? Date and time datatypes?

2008-02-18 Thread Gilles Ganault
On Sat, 16 Feb 2008 11:29:29 +1100, BareFeet <[EMAIL PROTECTED]> wrote: > If you designate an integer column as also being the primary key, > then SQLite will auto assign its value incrementally each time > you insert a new row, unless you assign a value explicitly. In this case, why do we need