RE: [sqlite] Second Btree Transaction stuck at commit

2006-08-10 Thread William Chan
Hi Richard, I found out I did not solve the problem yesterday because the btree commit got stuck again. After some debugging, I saw the dirty list in the pager became circular and caused infinite loop... (maybe due to my misuse?) So I put in an extra check into the function makeDirty(PgHder *pPg

Re: [sqlite] Attach db code

2006-08-10 Thread Pablo Santacruz
First, connect to your db file. As this is the first connection this will be referred as 'main'. Then you need to attach a memory database. ATTACH DATABASE ":memory:" AS mem; Create your table definitions in memory, por example: CREATE TABLE mem.table1 (... You can get some info from: SELECT sql

[sqlite] Attach db code

2006-08-10 Thread Manzoor Ilahi Tamimy
Hi All, Can someone give me the code you use to attach a database. I have a db file with 5 Million records and have three different tables. Index is also created in it. I want to load it in memory to apply some queries for testing. Best regards, Manzoor Ilahi Tamimy

Re: [sqlite] concurent writes and locks

2006-08-10 Thread Cory Nelson
On 8/10/06, Eric van der Maarel <[EMAIL PROTECTED]> wrote: John Stanton wrote: > Why not make your application simple and use a mutex to synchronize your > threads and serialize the database access? Well, I figure, if the db has an advanced locking/synchronization mechanism (that even makes a d

Re: [sqlite] Re: concurent writes and locks

2006-08-10 Thread Eric van der Maarel
Igor Tandetnik wrote: eric-5PSWdYX/[EMAIL PROTECTED] wrote: I have two threads heavily writing to the db. Hence, I get some SQLITE_BUSY return values. If I get it from sqlite3_step(), I wait a few ms and call sqlite3_step() again etc. This happens in one thread, thread A. The other thread (t

Re: [sqlite] concurent writes and locks

2006-08-10 Thread Eric van der Maarel
John Stanton wrote: Why not make your application simple and use a mutex to synchronize your threads and serialize the database access? Well, I figure, if the db has an advanced locking/synchronization mechanism (that even makes a distinction between reads and writes), using that will actuall

[sqlite] Re: More on triggers

2006-08-10 Thread Igor Tandetnik
chetana bhargav wrote: If two tasks create two seperate triggers each of its own, on the same condition each not caring whether already a trigger exists, and both of them had opened a session, now if the trigger is fired which one will be notified? First, triggers are parts of the database,

[sqlite] java applet access to sqlite on an arm architecture?

2006-08-10 Thread Keiichi McGuire
Hello, I was wondering if it is possible for a java applet to access sqlite2.8 databases that is installed on an arm architecture. Currently the arm system has apache, php and sqlite installed. The applet will run on windows/linux machine via a browser, but the applet file will be accessed throug

Re: [sqlite] Disable custom collate

2006-08-10 Thread Nuno Lucas
On 8/10/06, JP <[EMAIL PROTECTED]> wrote: I created a table with a field and index that uses a custom collation function MYCOLLATE. The problem I am having is portability, I cannot perform simple selects on the table on other sqlite based applications since the custom collation function is not a

Re: [sqlite] concurent writes and locks

2006-08-10 Thread John Stanton
Why not make your application simple and use a mutex to synchronize your threads and serialize the database access? [EMAIL PROTECTED] wrote: I have two threads heavily writing to the db. Hence, I get some SQLITE_BUSY return values. If I get it from sqlite3_step(), I wait a few ms and call sqli

[sqlite] Disable custom collate

2006-08-10 Thread JP
Hi, I created a table with a field and index that uses a custom collation function MYCOLLATE. The problem I am having is portability, I cannot perform simple selects on the table on other sqlite based applications since the custom collation function is not available. Does anybody out ther

[sqlite] More on triggers

2006-08-10 Thread chetana bhargav
Hi, I just want to confirm one more thing, If two tasks create two seperate triggers each of its own, on the same condition each not caring whether already a trigger exists, and both of them had opened a session, now if the trigger is fired which one will be notified? 1) First

[sqlite] SQLite BCB3

2006-08-10 Thread JJ Thymes
I've found the answer to my earlier post. In order to use SQLite with BCB3 Pro windows application you must 1) Uncheck "Use Dynamic RTL" 2) Uncheck "Build with run time Packages" -- Forwarded message -- From: JJ Thymes <[EMAIL PROTECTED]> Date: Aug 9, 2006 11:30 AM Subject: SQL

Re: [sqlite] SQLite and Java

2006-08-10 Thread Martin Jenkins
Umesh Nayak wrote: Dear all, Does SQLite work with Java? http://www.google.co.uk/search?hl=en&q=java+sqlite&btnG=Google+Search&meta= Martin ;)

[sqlite] Re: concurent writes and locks

2006-08-10 Thread Igor Tandetnik
eric-5PSWdYX/[EMAIL PROTECTED] wrote: I have two threads heavily writing to the db. Hence, I get some SQLITE_BUSY return values. If I get it from sqlite3_step(), I wait a few ms and call sqlite3_step() again etc. This happens in one thread, thread A. The other thread (thread B) however, is call

Re: [sqlite] Re: Foreign Keys

2006-08-10 Thread John Newby
Hi all, thanks for the infor on foreign keys, helps a lot. Thanks again John On 10/08/06, A. Pagaltzis <[EMAIL PROTECTED]> wrote: * John Newby <[EMAIL PROTECTED]> [2006-08-10 00:25]: > it recognises them if you put them in your create table > statement but it does not enforce them, is this co

[sqlite] concurent writes and locks

2006-08-10 Thread eric
I have two threads heavily writing to the db. Hence, I get some SQLITE_BUSY return values. If I get it from sqlite3_step(), I wait a few ms and call sqlite3_step() again etc. This happens in one thread, thread A. The other thread (thread B) however, is calling the registered busy handler while ex