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

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 01-30-2013, 04:46 PM   #1
PaleoRDR
Stone Tablet Reader
PaleoRDR began at the beginning.
 
Posts: 7
Karma: 10
Join Date: Mar 2010
Location: USA
Device: iPhone
How to Identify Which Ebooks Are Outdated?

This is a longstanding problem that I've been trying to figure out a way around. Hopefully someone here knows a quick solution.

As you're aware, updating the metadata for a book does not cause the ebook to be rebuilt. This results in a synchronization issue in which the metatadata embedded in the ebook format itself (I'm primarily concerned with ePub, though it is an issue for many formats) is out of sync with that in the database.

This has become a much larger problem for me recently, as I'm now using Calibre Companion to manage my Library on my android device. The problem is that the sync process CC uses is only sensitive to the last_modified entry in the database. If I update the comments on an ebook under Calibre, but fail to rebuild the epub, I end up with a situation where the epub on my android doesn't match the metadata. Also, if I subsequently do a rebuild on the epub, the last_modified field doesn't get updated and CC won't download the revised epub on the next sync.

What I need is a way to identify which books are currently in this condition. Is there a way under Calibre to select all books in which the specified format file (epub in this case) is older than the last_modified tag? It seems like this would be a built-in function, but I haven't been able to find it.

I suppose that I could write a script to walk the directory structure of the Library and flag all books in which the timestamp on the metadata.opf file is newer than that of the epub, but that would still leave me manually negotiating the GUI to initiate rebuilds for each individual book. Alternatively, I could just initiate a complete rebuild of every book in the library on a regular basis, but this isn't really practical with 15K+ books in the Library.

Anybody got any ideas? This issue would apply to any format of ebook that can contain embedded metadata.
PaleoRDR is offline   Reply With Quote
Old 01-30-2013, 05:34 PM   #2
chaley
Grand Sorcerer
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: 11,731
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
You can get the number of days between the metadata's last modified time and the modtime of EPUB formats with the template
Code:
{last_modified:'days_between($, select(formats_modtimes('iso'), 'EPUB'))'}
chaley is offline   Reply With Quote
Advert
Old 10-12-2013, 08:21 PM   #3
Rob557
Zealot
Rob557 has learned how to read e-booksRob557 has learned how to read e-booksRob557 has learned how to read e-booksRob557 has learned how to read e-booksRob557 has learned how to read e-booksRob557 has learned how to read e-booksRob557 has learned how to read e-books
 
Posts: 108
Karma: 810
Join Date: Jul 2012
Device: Kobo
Just belatedly noting the usefulness of chaley's script above, and cross-referencing to some related comments regarding using the script: https://www.mobileread.com/forums/sho...d.php?t=224440

Last edited by Rob557; 10-12-2013 at 08:24 PM.
Rob557 is offline   Reply With Quote
Old 10-14-2013, 09:44 AM   #4
Pierre-Olivier
Enthusiast
Pierre-Olivier began at the beginning.
 
Posts: 47
Karma: 30
Join Date: Jan 2010
Location: Dans les Landes ...
Device: PocketBook Touch Lux 3
Chaley, could you explain where using this template. I know absolutely nothing about templates

Thank you
Pierre-Olivier is offline   Reply With Quote
Old 10-14-2013, 11:12 AM   #5
chaley
Grand Sorcerer
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: 11,731
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by Pierre-Olivier View Post
Chaley, could you explain where using this template. I know absolutely nothing about templates

Thank you
In this case, the template goes into the "template" box of a custom column of type "column built from other columns". See calibre tips and tricks - calibre custom columns for more information on creating custom columns. See The calibre template language for more information on templates.
chaley is offline   Reply With Quote
Advert
Old 10-14-2013, 08:47 PM   #6
Pierre-Olivier
Enthusiast
Pierre-Olivier began at the beginning.
 
Posts: 47
Karma: 30
Join Date: Jan 2010
Location: Dans les Landes ...
Device: PocketBook Touch Lux 3
Thank you for your quick answer.
Pierre-Olivier is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
identify kf-8 files shorshe Kindle Formats 3 09-21-2012 01:27 PM
Outdated stories about ancient tech. ardeegee Lounge 1 05-28-2011 04:41 PM
How does Amazon identify ebooks? SpiderMatt Amazon Kindle 29 02-25-2011 10:23 AM
Help Me Identify A Title, Please MV64 Reading Recommendations 2 04-24-2009 10:21 AM
The Sony Reader will be outdated in 10 years TadW Sony Reader 39 11-25-2006 09:58 AM


All times are GMT -4. The time now is 05:35 AM.


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