Hi Michael I am using journal mode truncate. Explicitly, I am not running any pragma for synchronous. (i think, it's default value is 2 - Full).
Regards, d On Tue, Dec 11, 2012 at 5:08 PM, Michael Black <mdblac...@yahoo.com> wrote: > I don't see in the thread where you say what journal mode you're running in > or your synchronous setting. > That may explain your problem and be easily fixable. > > The other thing is to compile your system with stack protection and see if > that can trap the problem. > > If it's just stack corruption you should be able to trigger the error > locally much more quickly with stack protection on then in a random system. > > > > > > -----Original Message----- > From: sqlite-users-boun...@sqlite.org > [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of dd > Sent: Tuesday, December 11, 2012 1:00 AM > To: General Discussion of SQLite Database > Subject: Re: [sqlite] table backup > > Hi Roger, > > I don't have any clue. Two databases are corrupted. First one, while > inserting 20,000 records suddenly sqlite thrown disk io error at 4,000 > record. No clue. > > Second database corrupted when my application crashed. But that time, > second database was not opened. > > So, I am planning to choose backup solution instead of investigating > corruption. > > I discussed this issue in my previous post. > > Any sample application for virtual table option. > > Best Regards, > d > > > On Mon, Dec 10, 2012 at 9:09 PM, Roger Binns <rog...@rogerbinns.com> > wrote: > > > -----BEGIN PGP SIGNED MESSAGE----- > > Hash: SHA1 > > > > On 09/12/12 21:44, dd wrote: > > > Sometimes, sqlite databse corrupts. > > > > That is the problem you need to fix. If you have a system that is > > unreliable then it will also corrupt your backups. > > > > http://www.sqlite.org/lockingv3.html#how_to_corrupt > > http://www.sqlite.org/howtocorrupt.html > > > > > So, I want to take online backup of specific table. Not entire > > > database. > > > > Do you need to take a backup on every change, as part of the change or is > > it acceptable to make backups periodically and possibly lose intermediate > > versions of the data? > > > > For a periodic backup you can iterate over the table contents and output > > them in a convenient format for you, such as CSV or SQL statements. > > > > For saving all data you can use triggers to save historical values in a > > second table and then do a periodic backup. > > > > If it must be immediate then the only choice available is to use a > virtual > > table and do the backup during writes/sync. > > > > This is all considerably more work than figuring out why you are getting > > corruption in the first place. > > > > Roger > > -----BEGIN PGP SIGNATURE----- > > Version: GnuPG v1.4.11 (GNU/Linux) > > > > iEYEARECAAYFAlDGF2IACgkQmOOfHg372QTo9gCfSQQwreSvsa9lrV/wj0YC2Fvj > > LT0AmwdZSaNvVJJuic3gLYmQfn9YX6x3 > > =Gx1r > > -----END PGP SIGNATURE----- > > _______________________________________________ > > 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 > > _______________________________________________ > 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