On my laptop integrity_check fail

> PRAGMA integrity_check
> returns
>
> *** in database main ***
> rowid 0 missing from index JournalDateIndex
> rowid 0 missing from index sqlite_autoindex_Journal_1
> wrong # of entries in index JournalDateIndex
> wrong # of entries in index sqlite_autoindex_Journal_1

but I can continue to Insert new rows without any error.
Any new row has rowid = 1. Autoincrement algorithm does not work.

I'm looking for make my DB file more 'strong' and safe against this issue

Alessandro



From:
Simon Slavin <slav...@bigfraud.org>
To:
General Discussion of SQLite Database <sqlite-users@sqlite.org>
Date:
23/08/2011 18.44
Subject:
Re: [sqlite] Autoincrement failure




On 23 Aug 2011, at 4:28pm, a.azzol...@custom.it wrote:

> I cannot run a shell sqlite3 on my embedded system. I will explain it 
> using your example.

At some point your database file is becoming corrupt.

> It happen that sometime autoincrement begin to fail
> and new records overwrite the one at rowid =1
> 
> 1|1|2|3|one|two|three  replaced by 1|4|2|3|one|two|three
> 2|2|2|3|one|two|three
> 3|3|2|3|one|two|three

Can you stop at this point, copy the resulting database file back onto 
your desktop computer, and run

PRAGMA integrity_check()

on it using the shell tool ?

If it passes the integrity_check there, can you then execute the next 
INSERT on it, then do the same test ?

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to