Re: [sqlite] Detecting database corruption

2009-08-27 Thread Simon Slavin
On 27 Aug 2009, at 10:25pm, D. Richard Hipp wrote: > Chim is using a version of SQLite that is over 5 years old. The > behavior he describes is not present in any recent version of SQLite, > at least not as far as anyone is aware. Okay, problem solved. Thanks. Simon.

Re: [sqlite] Detecting database corruption

2009-08-27 Thread D. Richard Hipp
On Aug 27, 2009, at 5:05 PM, Simon Slavin wrote: > > On 27 Aug 2009, at 10:03pm, Chang Im (chim) wrote: > >> 1. pragma integrity_check >> >> It seems for a certain corruption, this command never returns. I >> have >> one database where the cmd ran 14 hours of CPU time, but it never >> came

Re: [sqlite] Detecting database corruption

2009-08-27 Thread Simon Slavin
On 27 Aug 2009, at 10:03pm, Chang Im (chim) wrote: > 1. pragma integrity_check > > It seems for a certain corruption, this command never returns. I have > one database where the cmd ran 14 hours of CPU time, but it never came > back. How do you tell when to stop in a case like this? I cannot

[sqlite] Detecting database corruption

2009-08-27 Thread Chang Im (chim)
Hi, I posted a similar question under "integrity check", but did not get much attention. I am a newcomer to SQLite and we uses SQLite 2 database in our embedded product line. As database corruption could happen due to various reasons, how do folks detect it, especially in embedded environment.

Re: [sqlite] detecting database corruption?

2005-10-14 Thread drh
Wilson Yeung <[EMAIL PROTECTED]> wrote: > > Does SQLite detect database corruption? If so, what kind of > corruption is detected and how does it do so? > SQLite does attempt to detect corruption in database files and returns SQLITE_CORRUPT when it finds it. The regression test suite for

[sqlite] detecting database corruption?

2005-10-13 Thread Wilson Yeung
I am currently writing software that will be shipped directly to consumers, and have SQLite embedded. The application is multi-threaded and I have: Reader-Writer Thread: begin transaction; write; write; read; write; read; end transaction; rinse-repeat Reader Thread: read; read; read For