Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 06-09-2013, 02:13 PM   #1
Statch
Connoisseur
Statch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it is
 
Statch's Avatar
 
Posts: 96
Karma: 2084
Join Date: Aug 2008
Location: Georgia, USA
Device: Kindle PW2, Samsung Galaxy 3, Kindle Fire HD
Custom column problem

A while back I decided to get fancy and try to set up Calibre via Sugarsync so that I could see my Calibre library from each of our computers, but without really understanding what I was doing. Somehow I ended up with duplicates of most of my books. I delinked the library (so I'm back to just backing up my Calibre library in Sugarsync) and sorted out the duplication problem (can't remember what I did to fix it now).

After a while, I realized that I had lost a custom column I created to record comments on books I've read. I can't even remember what I called the column. I still have the tags that I had used prior to 'fixing' the library. Is it possible that the custom comments field I had is still there somewhere in the metadata? How would I find it? Thanks in advance if anyone can help!

And just in case this happens to anyone else: I realized today that somehow I had accidentally applied the tag 'unread' to all of my books. I was able to fix it by using the fact that I rate books after I read them. So I clicked on Rating on the left, then highlighted all the books with ratings, clicked on Edit Metadata -> Edit Metadata in Bulk, then put 'unread' in the 'remove tags' section and applied it.
Statch is offline   Reply With Quote
Old 06-09-2013, 04:49 PM   #2
Statch
Connoisseur
Statch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it is
 
Statch's Avatar
 
Posts: 96
Karma: 2084
Join Date: Aug 2008
Location: Georgia, USA
Device: Kindle PW2, Samsung Galaxy 3, Kindle Fire HD
More...

I found the cmd line calibredb commands, so I used the show_metadata option to look at the metadata for books I think I had used the custom column to write comments about. Unfortunately, I don't see any of my comments in the metadata. Does that likely mean my data is gone?
Statch is offline   Reply With Quote
Old 06-11-2013, 11:05 PM   #3
goldilocks
Addict
goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.goldilocks ought to be getting tired of karma fortunes by now.
 
Posts: 231
Karma: 1028386
Join Date: Aug 2009
Location: Florida
Device: Sony PRS-505
Did you go into Preferences, Add your own columns, and check to see if your custom column is still listed and checked?

Maybe someone will come along that can really help you...
goldilocks is offline   Reply With Quote
Old 06-12-2013, 04:44 AM   #4
chaley
"chaley", not "charley"
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 5,927
Karma: 1673776
Join Date: Jan 2010
Location: France
Device: Many android devices
If the columns aren't in the list shown in preferences -> add your own columns then the columns are gone from the database.

If you are very lucky the data might still be in the backup OPFs that calibre creates for each book. Go to the folder for a book that you know should have data in one of the columns and look at the file "metadata.opf" in a text editor. Search for the lookup key for the column (as in #mumble). If that key is there, and if the data is somewhere around the key, then you might be in luck.

To get the data back (as much of it that still exists), you must destroy your library and recreate it. This is not for the faint of heart. Your mileage will vary. It might not get much data back. You may waste hours for little, or even negative, benefit.

The steps:

1) MAKE A BACKUP of the entire library. Almost certainly something will go wrong at least once in this process, and you really really want to be able to put everything back.

2) After making the backup (and preferably testing it) and with calibre not running, in the original library remove the files metadata.db and metadata_db_prefs_backup.json.

3) Open a command window, go to the folder that used to contain the metadata.db file, and run the command
Code:
calibredb --library-path=. --really-do-it
calibre will chug along for some time, rebuilding the database from the information in the metadata.opf backup files.

Please note that the process can lose data. If some metadata.opf files are missing or corrupt then those books will not be added. Information in the DB not directly related to books, such as user categories and saved searches, will be lost. Other bad things can happen. If the result isn't satisfactory, restore your backup.

Recovering a database this way was intended for use as a last resort. You should decide whether this is one of those cases.
chaley is offline   Reply With Quote
Old 06-13-2013, 09:22 PM   #5
Statch
Connoisseur
Statch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it isStatch knows what time it is
 
Statch's Avatar
 
Posts: 96
Karma: 2084
Join Date: Aug 2008
Location: Georgia, USA
Device: Kindle PW2, Samsung Galaxy 3, Kindle Fire HD
Thank you!

Thanks very much for the response and for the detailed information! I think I am not going to risk it. I've been keeping a spreadsheet for years that has both my print book and my ebooks, and I've been keeping comments there as well. Lately I had started putting them in Calibre only, but I had still been rating books in both the spreadsheet and Calibre, so I still have a reference to use. Fortunately I never got too elaborate with the Calibre comments, so I haven't lost a huge amount of work.

I had meant at some point to enter my print books into Calibre too and stop using the spreadsheet. Glad I didn't do it!

Again, I REALLY appreciate your time. I'm sorry I didn't respond earlier. Unexpected life stuff got in the way, but I should have checked in to look for responses.
Statch is offline   Reply With Quote
Old 06-14-2013, 02:10 PM   #6
Sabardeyn
Guru
Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.
 
Sabardeyn's Avatar
 
Posts: 630
Karma: 1242364
Join Date: May 2009
Location: The Right Coast
Device: PC (Calibre), Nexus 7 2013 (Moon+ Pro), HTC HD2/Leo (Freda)
Statch,
I've found that the first 3-6 "real" databases you create and try populating end up being failures for various reasons. At least one of which will be accidental destruction of data; one other will be an error in a customizing attempt.

Dummy databases - created just to see how calibre handles something - do not count.
Sabardeyn is offline   Reply With Quote
Old 06-14-2013, 03:03 PM   #7
BetterRed
null operator
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 4,041
Karma: 2925589
Join Date: Mar 2012
Location: NSW Australia
Device: none
@Statch - if I want to try something I regard as 'risky', I install a Calibre Portable in a throw away folder and play around it in it for a while, before deciding whether or not "I really want to do that"

BR
BetterRed is offline   Reply With Quote
Reply

Tags
custom columns

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom yes/no column built from long text column Philantrop Library Management 7 03-23-2013 08:44 PM
how to move value(s) of tag column to a custom made column zoorakhan Library Management 0 12-08-2012 04:53 AM
custom date column from two state column Dopedangel Library Management 7 01-03-2012 09:20 AM
Can custom book data be displayed in a custom column? kiwidude Development 9 03-02-2011 06:35 AM
Custom Column Problem MSJim Calibre 7 09-08-2010 06:07 PM


All times are GMT -4. The time now is 03:33 PM.


MobileRead.com is a privately owned, operated and funded community.