[sqlite] change path of journal file
Hello everyone, i'd like to know if its possible to change the path of the journal file which is automaticly generated when i'm starting a transaction. I'm currently trying to import data from a database on a DVD to a local database and i'm getting an error because i can't write on the dvd. -- GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT! Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01 ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Re: [sqlite] SQLite3: Database is sometimes locked when a reader is attached with open_v2
Hi Marcus, I have no problem when the reading application gets a lock error because the writing application has a lock. But the problem is the other way around: -> The writing application gets a lock error because someone reads! This is what I can't understand and what I didn't expect. I would expect that the writing application is undisturbed by any readers that open with SQLITE_OPEN_READONLY. Thanks Tino -- Marcus Grimm wrote: > I'm afraid this is by design of sqlite: Sqlite will lock > the database during a writing transaction, I think no matter > if you open a 2nd connection using the readonly flag. > > the typical solutions are: > a) retry your read attempt after you receive a busy error code until > it proceeds. > b) consider shared cache mode and pragma read_uncommitted = True; > > hope this helps > > Marcus ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
[sqlite] SQLite3: Database is sometimes locked when a reader is attached with open_v2
Hi all, I have written a program that opens a SQLIte3 database and writes in it most of the time via replace/update. If I do select like (no writes, really only reads) statements from some other process that carefully opens the database with "sqlite3_open_v2(..., SQLITE_OPEN_READONLY, ...)" the main (writing) application might get errcode=5 ermmsg='database is locked' errors when it tries to write while the other application (only!) reads. How is that possible? How to prevent? I would expect that the reading application might (of course) sometimes get "database is locked" errors, but the writing application should never. [ I have also realized that the sqlite3 commandline tool uses sqlite_open() and always opens in read/write mode. That's why I wrote my own reading application using sqlite3_open_v2 ] Thanks Tino ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
[sqlite] time is off
example: sqlite> select datetime('now'); 2006-09-18 10:11:48 sqlite> select datetime('now','utc'); 2006-09-18 08:11:52 sqlite> select datetime('now','localtime'); 2006-09-18 12:11:58 select datetime('now') shows utc time, Localtime shows my localtime, but now,utc is off. It should be the same as datetime('now'). Why is this?