Re: [sqlite] sqlite on VPS configurations

2007-05-10 Thread drh
Dave Dyer <[EMAIL PROTECTED]> wrote: > Is there any suspicion that sqlite might fail on virtual > unix server configurations? The http://www.sqlite.org/ website is on a virtual unix server. It uses SQLite extensively without any problems. But I guess it really depends on what virtual unix

[sqlite] Regexp

2007-05-10 Thread T
Hi, I noticed in recent versions of SQLite the addition of some functions such as Trim(). So I am hopeful that at least one more function, Regexp(), can be included since it is such a central and common need. Time and time again I come up with needing a Regexp function, and I notice that

Re: [sqlite] database is locked error

2007-05-10 Thread T
Is there a timetable for including the fix for opening SQLite files on a shared volume? Since it's fairly trivial, is there a reason why it hasn't been included yet? Thanks, Tom From: T <[EMAIL PROTECTED]> Date: 29 April 2007 3:35:00 AM To: sqlite-users@sqlite.org Subject: Re:

[sqlite] sqlite on VPS configurations

2007-05-10 Thread Dave Dyer
Is there any suspicion that sqlite might fail on virtual unix server configurations? Among other things that might be odd in this kind of environment, perhaps the relationship between disk locks and physical activity might be tenuous, and there might be genuine multiprocessors.

Re: [sqlite] indexing large databases

2007-05-10 Thread drh
Kasper Daniel Hansen <[EMAIL PROTECTED]> wrote: > > Having said that, I can understand that sorting and disk cache and so > on factors in - but my initial database is already very large (1.3GB > - 145.000.000 milion rows), and surely that disk cache would already > factor in at that stage?

[sqlite] Re: Longest "real" SQL statement

2007-05-10 Thread Charles Cazabon
Sorry for the lateness of this reply. I don't have the query anymore (wrote it at my previous job), and it wasn't specifically for sqlite, but here goes. A company I worked for built a system to calculate and report various health statistics from a huge database which was itself a composite of

Re: [sqlite] Database locked version 3.3.17

2007-05-10 Thread Ken
Resolved the issue. My issue on the app side. I think the newer version is much faster. So much so that it changed timing characteristics and reveald a logic bug in my code. Appologies, Ken Ken <[EMAIL PROTECTED]> wrote: Hi all, Think I may have hit some form of a bug in

Re: [sqlite] indexing large databases

2007-05-10 Thread Kasper Daniel Hansen
On May 10, 2007, at 3:04 PM, [EMAIL PROTECTED] wrote: Kasper Daniel Hansen <[EMAIL PROTECTED]> wrote: Hi We are using SQLite for a fairly big (but simple) calculation, and have some problems when creating an index on a database with 600.000.000 rows. Specifically it has not ended even after

Re: [sqlite] indexing large databases

2007-05-10 Thread drh
Kasper Daniel Hansen <[EMAIL PROTECTED]> wrote: > Hi > > We are using SQLite for a fairly big (but simple) calculation, and > have some problems when creating an index on a database with > 600.000.000 rows. Specifically it has not ended even after 5 days of > running. We have done it

[sqlite] indexing large databases

2007-05-10 Thread Kasper Daniel Hansen
Hi We are using SQLite for a fairly big (but simple) calculation, and have some problems when creating an index on a database with 600.000.000 rows. Specifically it has not ended even after 5 days of running. We have done it successfully on 25% of the full data base, and are now

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Derrell . Lipman
Brandon Eley <[EMAIL PROTECTED]> writes: > No, I can't upgrade to PHP5, yet. We're on PHP4. I was accessing sqlite 2.8.x databases with PHP4 a number of years ago. It worked fine. The page I referred you to previously _initially_ discusses the object interface for the sqlite functions. That,

[sqlite] Database locked version 3.3.17

2007-05-10 Thread Ken
Hi all, Think I may have hit some form of a bug in 3.3.17: At an insert statement I'm getting a rc=[5] msg=[database is locked] When I recompile the sqlite using version 3.3.13 and re-run the appliation. No problems. Sorry this is pretty vague.. I'll try digging in more and finding

Re: [sqlite] The need for sqlite3_encode_binary and sqlite3_decode_binary

2007-05-10 Thread Andrew Finkenstadt
much thanks. My background is as a very strongly performance-oriented Oracle developer and DBA, and nearly every example I see for using sqlite3 uses non-optimal techniques which either blow through memory allocations, or become subject to SQL-injection attacks. On a related note, what's the

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Derrell . Lipman
Brandon Eley <[EMAIL PROTECTED]> writes: > Thank you for this information. How would I access the 2.8.x database from > within PHP? is it even possible? Go to http://www.php.net. Type "sqlite" into the search box at the top. The page it brings you to describes the sqlite 2.8.x interface. The

Re: [sqlite] Longest "real" SQL statement

2007-05-10 Thread BardzoTajneKonto
I haven't used SQLite for that yet (I will in the near future) but with mysql my longes statement was at least several megabytes. I create statements automatically. I think so far the longes created statement was a PCA trafsformation from table with about 2000 columns (would have been more if

Re: [sqlite] My HPUX Notes

2007-05-10 Thread John Stanton
Markus Hoenicka wrote: Quoting km4hr <[EMAIL PROTECTED]>: I just happened to notice that I may not be executing the sqlite installation process (configure/make/make install) in a full "bash" environment. My usual environment is "ksh". Typing in the command "/bin/OpenSource/bin/bash" I get a

Re: [sqlite] The need for sqlite3_encode_binary and sqlite3_decode_binary

2007-05-10 Thread Dennis Cote
Andrew Finkenstadt wrote: It would appear that by using bind variables instead of '%Q' in the SQL string, the need for sqlite3_encode_binary and sqlite3_decode_binary is eliminated. Is that indeed the case? Andy, Yes that is the case. You can use sqlite3_bind_blob to pass arbitrary binary

Re: [sqlite] sql stack using sqlite

2007-05-10 Thread Ken
I think i found an ok solution: (note I've updated my own insert statements from the OP) drop table purg; create temporary table purg (id integer primary key, tbl); -- Use the fact that the Puging tables C unique ID is always after table A's data. insert into purg select distinct

Re: [sqlite] DBD::SQLite with FTS

2007-05-10 Thread Tomash Brechko
On Thu, May 10, 2007 at 08:04:51 -0500, P Kishor wrote: > are there any guidelines on how to hook a new SQLite lib with the > DBD package since the CPAN version seems to be running a few > versions late. No special actions needed, default build of DBD::SQLite will use pre-installed shared library

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread T
Hi Brandon, Is there a way to upgrade the module to SQLite 3 on PHP4? I think so. I recall reading something about it, but since I was able to just install PHP5 I went via that route. Try Google: http://www.google.com.au/search?q=SQLite3+PHP4 Tom

Re: [sqlite] Longest "real" SQL statement

2007-05-10 Thread T
Hi Richard, I tend to use a series of CREATE VIEW AS SELECT type statements to effectively nest my SELECT statements, making them more humanly editable and manageable. Consequently, the size of the maximum sized single SQL statement is reduced, though the total SQL statement effectively

RE: [sqlite] Longest "real" SQL statement

2007-05-10 Thread Samuel R. Neff
We don't do it in SQLite but as an example of how large a legitimate SQL statement can be, in a previous project we generated a pseudo-cube from the current database in a single sql statement. Basically we wanted to implement a fast complex search routine where users can choose any fields from

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Brandon Eley
No, I can't upgrade to PHP5, yet. We're on PHP4. Brandon Eley [EMAIL PROTECTED] On May 10, 2007, at 9:04 AM, Chris Peachment wrote: I think I have misread your original posting. Can you upgrade your version of PHP? I use PHP version 5.2.1. Running phpinfo() reveals the PDO driver to be:

Re: [sqlite] My HPUX Notes

2007-05-10 Thread Markus Hoenicka
Quoting km4hr <[EMAIL PROTECTED]>: I just happened to notice that I may not be executing the sqlite installation process (configure/make/make install) in a full "bash" environment. My usual environment is "ksh". Typing in the command "/bin/OpenSource/bin/bash" I get a bash prompt. But

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Brandon Eley
It's ShopSite (www.shopsite.com) and I'm building add-on modules for the cart that need to access information in the DB. Unfortunately, we can't upgrade to PHP5 just yet, as we have quite a few sites on the server running open source software and we haven't verified they are all compatible

[sqlite] DBD::SQLite with FTS

2007-05-10 Thread P Kishor
has anyone created a DBD::SQLite with the full-text search option turned on? else, are there any guidelines on how to hook a new SQLite lib with the DBD package since the CPAN version seems to be running a few versions late. -- Puneet Kishor http://punkish.eidesis.org/ Nelson Inst. for Env.

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Chris Peachment
I think I have misread your original posting. Can you upgrade your version of PHP? I use PHP version 5.2.1. Running phpinfo() reveals the PDO driver to be: PECL version: 1.0.1 $Id: pdo_sqlite.c,v 1.10.2.6.2.1 2007/01/01 09:36:05 sebastian Exp $ Sqlite Library: 3.3.7undefined Since you can run

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Ulrich Schöbel
It's the other way round: Your database is 3.x, your SQLite library used by PHP is 2.8.14. Upgrade your PHP. Ulrich On Thursday 10 May 2007 14:46, Brandon Eley wrote: > Thank you for this information. How would I access the 2.8.x database > from within PHP? is it even possible? > > The database

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread T
Hi Brandon, I've had my web host install the PECL extension and the following is what is in my phpinfo(); sqlite SQLite support enabled PECL Module version 1.0.3 $Id: sqlite.c,v 1.62.2.25 2004/07/10 SQLite Library 2.8.14 How would I access the 2.8.x database from within PHP? is it

Re: [sqlite] My HPUX Notes

2007-05-10 Thread km4hr
Essien Essien wrote: > > that was really funny you know :) Always a pleasure to provide entertainment for my friends. > > On POSIX systems you're supposed to do three things to get your > software installed (usually a standard set of three commands). > > 1. ./configure (some packages leave

[sqlite] PHP5 and SQLite3 and SQLite2

2007-05-10 Thread Al Rider
As I understand it, SQLite2 files are not compatible with SQLite3. This poses a dilemma for me and I would guess many others on shared, virtual webhosts. The docs say to simply have both versions installed and copy from vers 2 to vers 3. That's OK for dedicated servers; but, most of us who

Re: [sqlite] A suggestion

2007-05-10 Thread Trey Mack
Works for me straight out of the box on Windows XP. That program does have the capability, but may not be implemented that way on Windows. Why not make the change yourself? A.J.Millan wrote: As a suggestion, and even in the risk to abuse of Mr Hipp's patience. Would it be possible to

Re: [sqlite] Problem with SQLite Pecl extension for PHP4

2007-05-10 Thread Brandon Eley
Thank you for this information. How would I access the 2.8.x database from within PHP? is it even possible? The database is created from a shopping cart program, so I can't upgrade it, it has to remain the same version (for now). Brandon Eley [EMAIL PROTECTED] On May 9, 2007, at 10:59

Re: [sqlite] Longest "real" SQL statement

2007-05-10 Thread Stephen Toney
Hi Richard, Our longest select so far this one: select * from log where ((aut not like '6%' and aut not like '-1%') or (avm not like '6%' and avm not like '-1%') or (lam not like '6%' and lam not like '-1%') or (pam not like '6%' and pam not like '-1%') or (pas not like '6%' and pas not like

[sqlite] explain query plan/timing

2007-05-10 Thread bash
Hello All, I've tried to find documentation/help about how to read output from EXPLAIN QUERY PLAN but without success. Can you point me where i can get it. And another question about timing/profiling for SQLite. Patch from this location

Re: [sqlite] sqlite3_last_insert_rowid : what will it return if we have more than one table?

2007-05-10 Thread drh
"B V, Phanisekhar" <[EMAIL PROTECTED]> wrote: > Assume I have two tables A and B in the databse. > > > > sqlite3_last_insert_rowid will return the rowid of which table? > The one you last inserted into. -- D. Richard Hipp <[EMAIL PROTECTED]>

[sqlite] sqlite3_last_insert_rowid : what will it return if we have more than one table?

2007-05-10 Thread B V, Phanisekhar
Assume I have two tables A and B in the databse. sqlite3_last_insert_rowid will return the rowid of which table? Regards, Phani

Re: [sqlite] ATTACH and sqlite3_open()

2007-05-10 Thread Dan Kennedy
On Wed, 2007-05-09 at 16:18 -0700, Jon Scully wrote: > Simpler than that. I merely want to attach to two databases (files). > flash.db contains a set of tables that hold non-volatile data; ram.db > contains a set of tables that is re-built (volatile) on re-boot -- but > offers fast, read-only

Re: [sqlite] create table error

2007-05-10 Thread Mohd Radzi Ibrahim
Could it be that the data where *sql is pointing to is being re-used somewhere? --radzi. - Original Message - From: <[EMAIL PROTECTED]> To: Sent: Thursday, May 10, 2007 3:54 PM Subject: [sqlite] create table error the following is my test code. just

[sqlite] Network share goes down, SQLite keeps trying

2007-05-10 Thread Jan Debis
Greetings, I'm working on a small win32 application that periodically writes data to a SQLite database located on a remote machine, the remote database file is opened with a UNC file name, e.g. \\remotemachine\share\path\to\db Now if the remote server that holds the database file gets shut down

[sqlite] create table error

2007-05-10 Thread allen . zhang
the following is my test code. just create table. rc = sqlite3_open("zieckey.db", ); char *sql = " CREATE TABLE SensorData(ID INTEGER PRIMARY KEY,SensorID INTEGER,SiteNum INTEGER,Time VARCHAR(12),SensorParameter REAL);" ; sqlite3_exec( db , sql , 0 , 0 , ); sqlite3_close(db); when

Re: [sqlite] Longest "real" SQL statement

2007-05-10 Thread miguel manese
I am the author of the package SQLiteDF for R (a statistical package), some sort of sqlite backed "data set". It's "raison d'etre" is to deal with very large datasets, which could be tables with thousands of columns. I am not much on the infinite length sql statement, but I need lots of columns

RE: [sqlite] Longest "real" SQL statement

2007-05-10 Thread RB Smissaert
This is one of my biggest and it is part of a number of queries to transpose a table: INSERT OR REPLACE INTO A3BP619_J(PATIENT_ID, ENTRY_ID_E1, START_DATE_E1, ADDED_DATE_E1, SYST_E1, DIAST_E1, ENTRY_ID_E2, START_DATE_E2, ADDED_DATE_E2, SYST_E2, DIAST_E2, ENTRY_ID_E3, START_DATE_E3, ADDED_DATE_E3,

Re: [sqlite] My HPUX Notes

2007-05-10 Thread Essien Essien
guess you missed all the smileys and innuendo in that reply then. On 5/8/07, Glenn <[EMAIL PROTECTED]> wrote: Essien Essien wrote: > that was really funny you know :) And your response was really obnoxious. You could have simply said that the common way to do things on POSIX is "./configure;