Add books ==> Add books from directories, including sub-directories (One book per directory, assumes every ebook file is the same book in a different format)
this can import books saved with save-to-disk as well as from a messed-up library, it reads data from the backup metadata.opf file as well. Run that (from a blank library) on your entire old library to recreate the old library. (Partially --some things won't be restored, including custom columns and other settings.)
Afterward, use the Find Duplicates plugin to cleanup and merge with the backup.
Then start taking backups more often.
I assume restore database failed because of duplicate book ids or something?