[gnucash-de] libdbi bug when opening existing gnucash file

Heinz Repp heinz.repp at freenet.de
Do Aug 12 09:59:40 EDT 2021


Am 11.08.21 um 21:01 schrieb Boris Blazej:
> Wenn ich versuche, das File mit einem sqlite-Viewer zu öffnen, bekomme
> ich übrigens je nach Tool beim öffnen oder beim ersten select-Statement
> die Fehlermeldung "database disk image is malformed".

Das weißt darauf hin, dass die Datenbank stark beschädigt ist. 
Stackoverflow hat dazu:

> UPDATE: There is now an automatic method that is built into SQLite: .recover
> 
> Sometimes, the corruption is only or mostly in indexes, in which case it would be possible to get some or most records by trying to dump the entire database with .dump, and use those commands to create a new database:
> 
> $ sqlite3 mydata.db ".dump" | sqlite3 new.db
> 
> However, this is not always possible.
> 
> The easiest and most reliable way is to restore the database file from the backup.

Da würde ich weiter machen, wenn die Daten wirklich wichtig sind - also 
erst im sqlite-Binary .recover und wenn das nicht hilft, dump und in 
neue Datenbank einlesen.

Gruß

Heinz

Und BTW: das ist kein libdbi-Bug, sondern eine beschädigte Datenbank.


Mehr Informationen über die Mailingliste gnucash-de