On Thu, Mar 20, 2014 at 7:18 PM, Tim Streater <t...@clothears.org.uk> wrote:
> I had a case where attempts to access a table in a user's db gave "no such > table", where 60 mins previously (according to the log) querying that table > gave no problems. About a day and a half later the user's machine had what > he described as a "bad crash", so I'm suspecting he has a failing disk. Due > to a separate coincidence, this meant the app could not restart. > > Now, I want to protect against this or give better warning, and I am > wondering whether corruption looking like a missing table would be caught > by the integrity_check pragma. > PRAGMA integrity_check catches most things. PRAGMA quick_check also does a good job, and it is much faster. The only difference is that quick_check does not verify that indices agree with tables, whereas a full integrity_check does. There is also PRAGMA foreign_key_check to verify referential integrity. > > -- > Cheers -- Tim > > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > > -- D. Richard Hipp d...@sqlite.org _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users