Someone was asking me a question about what happens if the wrong
journal file gets applied to a database.  My answer was that terrible
things happen.

I found myself wondering if the "File change counter" value is stored
in the journal (*).  It would seem like a cheap(ish) way to give some
reasonable assertions about whether the journal belongs to the
database file it's being applied to.  But if it's in there, I'm not
having any luck finding it.  Has anyone already figured out that this
is true?

Thanks,
scott

(*) It would be more complicated than storing the original value.
You'd probably have to store both the original and the target.  And
that assumes that at rollback, the database file's header was either
completely overwritten or not written at all, which may not match
reality very well.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to