On Apr 6, 2010, at 9:15 AM, cliff 2 wrote: > > > cliff 2 wrote: >> >> >> Thanks very much for the quick response! Unfortunately, the android >> SQLiteDatabase class deletes the database when it hits this, so it >> doesn't >> give me a chance to do that. However I do have a channel to the >> android db >> developers, so I will forward this onto them, and hopefully they >> can do >> something with it. >> >> Thanks again for your help. >> >> >> >> D. Richard Hipp wrote: >>> >>> >>> ... >>>> >>>> Not sure at this point what kind of work-arounds are available to >>>> you. >>> >>> >>> To amplify what Shane said, the corruption is probably just in the >>> page cache, not in the database file itself. So if you are able to >>> close and reopen the database connection when you run into problems, >>> that might provide a work-around (assuming we are guessing correctly >>> at the root cause of your problem.) >>> >>> D. Richard Hipp >>> d...@hwaci.com >>> >>> >>> >>> _______________________________________________ >>> sqlite-users mailing list >>> sqlite-users@sqlite.org >>> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users >>> >>> >> >> > > We changed the db in question to only open in readonly mode when > doing a > select rather than using a writable connection all the time. This has > greatly reduced the frequency of this error occurring, though it still > occurs. Given that the closing and opening of the db when this > happens isn't > possible. Is there anything else you can think of that will further > reduce > the frequency of this occurring? Is there an operation that we can > avoid for > example?
Statically link your application against SQLite 3.6.23 instead of using the SQLite 3.5.9 that is found on Android. The bug you are hitting was fixed in SQLite 3.6.2. > > Even if the android guys can fix their end, there will still be a > large > number of devices deployed with the current version of android and > sqlite, > therefore anything we can do to minimize this would be useful. > -- > View this message in context: > http://old.nabble.com/Android-database-corruption-tp28044218p28151650.html > Sent from the SQLite mailing list archive at Nabble.com. > > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users D. Richard Hipp d...@hwaci.com _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users