Error; SQLite error 11 – database disk is malformed

RM 10 on Win 11. I had about the same earlier but I prefer to take the latest one up here, hoping for help.
One evening I left my database open at Places, I had been working there. When I next morning open that page I got an Error; SQLite error 11 – database disk is malformed.
I have tried to load up the newest copy from yesterday, the same happens. The Support tells me that the file is corrupted. they sugested to try a Gedcom file. I tried a Gedcom, but it stopped before finishing. I tried Tools/Test Integrity. It stopped with an error message. Reindexing went OK. I did these two twice, same result. Compact gave SQLite Elvia 19 - UNIQUE constraint Failed: PlaceTable. Place ID.
I then loaded up an earlier copy from 10th. August. Tried Tools/Test Integrity. That gave a long error list. I than ran a Gedcom Export/import, got no error message. I use that file now continuing at address list to correct and merge.

Can you try the GEDCOM in another program, like Gramps? It might give you some info about duplicate IDs, or other anomalies.

There may be other programs that can do similar checks.

You may also try this program on a copy of your database, to see whether it shows SQLite errror 11 too:

https://sqlitebrowser.org/

That is unfortunate. Post a screenshot of the Windows properties for the database file showing the full path to it (assuming you have not moved it).

The worst cause of this symptom is that your drive is failing and data corruption is spreading. Next best is that it is a one-time fault that is static. Exporting a GEDCOM is about all that Support can suggest beyond what Integrity Check, Rebuild Indexes, and Compact can do. That it failed confirms there is database corruption - where it stopped can give some idea where corruption was encountered or, at least, where it wasn’t. What was the Integrity Check error message(s)? I’m surprised that Reindexing succeeded whereas Compact gave the error report it did - the PlaceTable.PlaceID is a Primary Key that would be looked at by Reindex. If that is the only table that is corrupted, then it may be possible to salvage more of your work since the last good backup by using SQLite to copy records from it to replace many of the affected records in the bad database.

1 Like

I suggest that the user make a simple copy of the database file in the file manager.
If there are storage read errors, the copy operation may retry enough times to get a good read.
Then try integrity check again, on the copy.
The Compact command (Vacuum) does an in-place restructure. If the sectors are bad, that may not help.

1 Like

Here is a screen shot of a part of the latest Integrity check that was not OK.

Karleif

It’s best to restore a backup, make sure to run the database tools on it to rule out corruption there too.

Renee,
If you want to, have a look at the latest tickets with Diana and Jason, there have been problems since i got RM 10. I have ran Tools on and on, wont go thru. I am now at a file that was corrupted but I now use that file after gone thru Gedcom and I just now went thru the Tools without any problems.