View Single Post
Old 12-07-2011, 11:51 AM   #4
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,733
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
So either you have only one format per book or you want the date of the last format you added? But this doesn't matter, really.

I assume the date is from the file (the format) that you are importing, not the date of the format inside calibre's library. If so, then the answer is 'maybe'. Looking at the code, I see that adding a format via the edit metadata (single) dialog sets the modtime of the format in calibre's library to the modtime of the file being added. You can get that modtime using the template function formats_modtimes. If the book has more than one format, you would need to know which format you are interested in.

As far as I can tell, adding a book + format using the add function does not set the modtime in this way.
chaley is offline   Reply With Quote