Re: [sqlite] Re: Re: Cannot we reuse an sqlite3_stmt to insert multiple rows ?

2006-11-22 Thread Pyramide-Ingenierie Developer List
Hello, Le 22-nov.-06 à 21:08, Igor Tandetnik a écrit : Pyramide-Ingenierie Developer List <[EMAIL PROTECTED]> wrote: I try to use "sqlite3_reset()" and/or "sqlite3_clear_bindings()" before "re-binds" and "re-step" but I always get an error 21 (SQLITE_MISUSE) when I am calling them on a

[sqlite] strange.. two db files in sync ??!!

2006-11-22 Thread James. L
hello, i just notice something strange in sqlite. i have a db file which is a copy of another one(not a symlink). when i delete one row from a table in one db file and the same row got delete from the same table in the other db file as well. this happens when i tried dropping a table. this is

Re: [sqlite] Re: How to change priority in compound SELECTs?

2006-11-22 Thread Nan Ye
Thanks for your help! Sorry for just used an improper example for my question ;-) . That example dosen't have any logical meanings. I'd just like to know how to make the UNION occurs before the INTERSECT operation. Your advice is to import an extra SELECT clause on the UNION results. Will this

[sqlite] fastest way to transfer ADO recordset to SQLite db file

2006-11-22 Thread RB Smissaert
What is the fastest way in VB to transfer an ADO recordset to a SQLite .db file? I am using the dll from TerraInformatica, SQLiteDb.dll. This is what I have now: Set oSQLConn = New SQLiteDb.Connection With oSQLConn .ConnectionString = "Data Source=" & strReadSQLiteDB .Open

Re: [sqlite] Cannot we reuse an sqlite3_stmt to insert multiple rows ?

2006-11-22 Thread Dennis Cote
Pyramide-Ingenierie Developer List wrote: Hello, I am using SQLite 3.3.8 library on Mac OS X using XCode 2.4.1 (gcc 4.0)... I try to compile only once an SQL instruction like "INSERT INTO Book (author_fk,title,date,time,price,created) VALUES (?,?,?,?,?,?);" and insert multiple rows through

[sqlite] Rép : Re: Cannot we reuse an sqlite3_stmt to insert multiple rows ?

2006-11-22 Thread Pyramide-Ingenierie Developer List
Hello, Le 22-nov.-06 à 20:00, Igor Tandetnik a écrit : I try to use "sqlite3_reset()" and/or "sqlite3_clear_bindings()" before "re-binds" and "re-step" but I always get an error 21 (SQLITE_MISUSE) when I am calling them on a already used sqlite3_stmt... sqlite3_reset should work. You are

Re: [sqlite] A way to get SQLite type from decl type?

2006-11-22 Thread Joe Wilson
I think it would be a good addition to the SQLite API. Make a ticket, post the patch and see if DRH accepts it. As far as "circumventing" the API goes, for your use in RSQLite just make a copy of the function in question, rename it, have the function accept just a single argument (const char*

[sqlite] Re: Cannot we reuse an sqlite3_stmt to insert multiple rows ?

2006-11-22 Thread Igor Tandetnik
Pyramide-Ingenierie Developer List <[EMAIL PROTECTED]> wrote: I try to compile only once an SQL instruction like "INSERT INTO Book (author_fk,title,date,time,price,created) VALUES (?,?,?,?,?,?);" and insert multiple rows through a (sqlite3_bind_xxx / sqlite3_bind_step) loop but I everytime got

[sqlite] Re: use of ".indices"

2006-11-22 Thread Igor Tandetnik
Dixon Hutchinson wrote: Consider the sequence below with SQLite 3.3.7 on Windows: sqlite> CREATE TABLE xyzzy ...> ( ...> comp TEXT, ...> parent INTEGER, ...> ROWID INTEGER PRIMARY KEY AUTOINCREMENT, ...> UNIQUE(parent, comp) ...> ); sqlite> .indices

[sqlite] Cannot we reuse an sqlite3_stmt to insert multiple rows ?

2006-11-22 Thread Pyramide-Ingenierie Developer List
Hello, I am using SQLite 3.3.8 library on Mac OS X using XCode 2.4.1 (gcc 4.0)... I try to compile only once an SQL instruction like "INSERT INTO Book (author_fk,title,date,time,price,created) VALUES (?,?,?,?,?,?);" and insert multiple rows through a (sqlite3_bind_xxx /

[sqlite] use of ".indices"

2006-11-22 Thread Dixon Hutchinson
Consider the sequence below with SQLite 3.3.7 on Windows: sqlite> CREATE TABLE xyzzy ...> ( ...> comp TEXT, ...> parent INTEGER, ...> ROWID INTEGER PRIMARY KEY AUTOINCREMENT, ...> UNIQUE(parent, comp) ...> ); sqlite> .indices xyzzy

Re: [sqlite] A way to get SQLite type from decl type?

2006-11-22 Thread Seth Falcon
Joe Wilson <[EMAIL PROTECTED]> writes: > This is the internal code that sqlite uses to convert the > declaration type to the REAL, INT, TEXT, BLOB types. > > Happy hacking... Thanks for the pointer. I can create the appropriate struct and call sqlite3AffinityType and this gives me a solution.

[sqlite] INSERT INTO with external database?

2006-11-22 Thread RB Smissaert
In VB with an ODBC connection to an Interbase database it is possible to move data from Interbase to Access with a SQL construction like this: INSERT INTO ACCESSTABLE (SUBJECT_TYPE, READ_CODE, TERM30, TERM60) SELECT IB.SUBJECT_TYPE, IB.READ_CODE, IB.TERM30, IB.TERM60 FROM IBTABLE IB IN [ODBC;

Re: [sqlite] Slow performances with COLLATE NOCASE

2006-11-22 Thread Sergio 'OKreZ' Agosti
On 21/nov/06, at 17:07, Christian Smith wrote: Sergio 'OKreZ' Agosti uttered: Hi, I've a performance problem with an application written in realbasic, using a sqlite db: some of the tables have UNIQUE fields, and I've no problem with the default COLLATE mode (BINARY); but if I set

[sqlite] Re: How to change priority in compound SELECTs?

2006-11-22 Thread Igor Tandetnik
Nan Ye wrote: If I used UNION and INTERSECT in compound SELECTs, how to change the default priority? For example, SELECT id FROM sample_a WHERE value > 3.0 INTERSECT SELECT id FROM sample_b WHERE value < 4.0 UNION SELECT id FROM

RE: [sqlite] SQLite error: Database is locked

2006-11-22 Thread Denis Povshedny
Hi Rama! Unfortunatelly I haven't any experience with Linux. But I reproduce situation on my system (Win XP), and have noticed that after kiliing Process A files ~testDb.db3 ~testDb.db3-journal are usable for Process B. Process B just reuse file ~testDb.db3-journal file for own needs, and

[sqlite] How to change priority in compound SELECTs?

2006-11-22 Thread Nan Ye
Hi, If I used UNION and INTERSECT in compound SELECTs, how to change the default priority? For example, SELECT id FROM sample_a WHERE value > 3.0 INTERSECT SELECT id FROM sample_b WHERE value < 4.0 UNION SELECT id FROM sample_b WHERE value > 7.0; The default results is that it