Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 03-23-2013, 09:45 PM   #1
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Correcting metadata for kepub books

I have noticed a few inconsistencies in the metadata for kepub books bought from Kobo. For sideloaded books it is no problem to correct the metadata in Calibre before sending the book to the reader, but I don't think I can do that for kepubs.

One example is the format of the author's name. I bought the first two books in Steven Erikson's Malazan Book of the Fallen series. Although both books ae by the same publisher, on my Glo the first book shows the author as "Erikson, Steven" but the second book shows as "Steven Erikson".

This causes an issue when browsing or searching by author: although the books are both correctly sorted by the author's last name, they are treated as being by different authors, so all books by "Erikson, Steven" are listed ahead of any books by "Steven Erikson". It also affects the predictive search function because selecting the completion "Steven Erikson" will not show books by "Erikson, Steven" in the search results.

So do you think it would be safe to change the author metadata for kepubs by directly editing the Kobo device's database?
GeoffR is offline   Reply With Quote
Old 03-23-2013, 10:35 PM   #2
murg
No Comment
murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.
 
Posts: 3,238
Karma: 23878043
Join Date: Jan 2012
Location: Australia
Device: Kobo: Not just an eReader, it's an adventure!
Just had a quick check. The .opf file in a .kepub is not encypted.

Rename the .kepub to .zip. Unzip it. Edit the .opf file using any simple text file editor. Rezip the file. Rename the file back to .kepub.

I have not actually done this, but it will probably work, unless there is some gotcha...
murg is offline   Reply With Quote
Advert
Old 03-23-2013, 10:48 PM   #3
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
It has never caused me any problems. The main change I do is the series info, but I have changed most of the metadata in the database for kepubs.

For my curiosity, do you have the books loaded in calibre? Either the epub version or an empty book with the metadata filled in appropriately so that they match.
davidfor is offline   Reply With Quote
Old 03-24-2013, 04:41 AM   #4
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Quote:
Originally Posted by murg View Post
Rename the .kepub to .zip. Unzip it. Edit the .opf file using any simple text file editor. Rezip the file. Rename the file back to .kepub.
But wouldthe device re-read the file or even notice that it was changed? I didn't try it out as modifying the database directly seems to work OK. Of course either way I lose the changes next time I log out of my account.

Quote:
Originally Posted by davidfor View Post
It has never caused me any problems. The main change I do is the series info, but I have changed most of the metadata in the database for kepubs.

For my curiosity, do you have the books loaded in calibre? Either the epub version or an empty book with the metadata filled in appropriately so that they match.
I have the epub versions in Calibre with the author name on both set to "Steven Erikson", Calibre matched them to the kepubs and set the series info for the kepubs from the epubs as expected.

I ran the following command from sqlite3 to change the author name, it seems to have worked as hoped, but I'll watch for problems for a while before I try any more changes.
Code:
UPDATE content
 SET Attribution='Steven Erikson'
 WHERE Attribution='Erikson, Steven';
GeoffR is offline   Reply With Quote
Old 03-24-2013, 06:53 AM   #5
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by GeoffR View Post
But wouldthe device re-read the file or even notice that it was changed? I didn't try it out as modifying the database directly seems to work OK. Of course either way I lose the changes next time I log out of my account.
As far as I can tell, downloaded kepubs are never read for their metadata. I am fairly sure the metadata is put into the database from the server. This is the only question I have about manually making the changes, whether a sync will override it.
Quote:
I have the epub versions in Calibre with the author name on both set to "Steven Erikson", Calibre matched them to the kepubs and set the series info for the kepubs from the epubs as expected.

I ran the following command from sqlite3 to change the author name, it seems to have worked as hoped, but I'll watch for problems for a while before I try any more changes.
Code:
UPDATE content
 SET Attribution='Steven Erikson'
 WHERE Attribution='Erikson, Steven';
That should work. But, my question was really a hint to try something else. Though maybe you want to update it first.
davidfor is offline   Reply With Quote
Advert
Old 03-24-2013, 04:14 PM   #6
murg
No Comment
murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.
 
Posts: 3,238
Karma: 23878043
Join Date: Jan 2012
Location: Australia
Device: Kobo: Not just an eReader, it's an adventure!
Quote:
Originally Posted by GeoffR View Post
But wouldthe device re-read the file or even notice that it was changed? I didn't try it out as modifying the database directly seems to work OK. Of course either way I lose the changes next time I log out of my account.;
I have no idea. With sideloaded epubs, replacing the book on the device will cause the book to be deleted (a long standing bug).

You may have to delete the .kepub, disconnect the device so the delete is processed, and then 'sideload' the kepub.

This is not a procedure I do (I rarely read kepubs), so I don't know how it works as well as I do the epub side.
murg is offline   Reply With Quote
Old 03-24-2013, 08:50 PM   #7
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Quote:
Originally Posted by davidfor View Post
As far as I can tell, downloaded kepubs are never read for their metadata. I am fairly sure the metadata is put into the database from the server. This is the only question I have about manually making the changes, whether a sync will override it.
At least some metadata seems to come directly from the server, such as the series information. But I would have thought that if the server were supplying the author name then it would match the name shown on the website, so maybe it is updates some metadata from the kepub file after download?

I know Kobo are updating the series information on their books bit by bit, but it does seem a bit haphazard. Some series have only one book (not always the first) with series information, others have different series names for books in the same series, and many have the series information duplicated in the title or subtitle. It would be a real mess if we didn't have Calibre to sort it all out :-)

Quote:
Originally Posted by murg View Post
You may have to delete the .kepub, disconnect the device so the delete is processed, and then 'sideload' the kepub.
That might work, but I don't want to sideload any kepubs if I can possibly avoid it, it seems like that would open the way for a lot more things going wrong. I'll stick to the method of updating the database, and just try to avoid changing anthing that affects the interaction between device and server.
GeoffR is offline   Reply With Quote
Old 03-25-2013, 02:03 AM   #8
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by GeoffR View Post
At least some metadata seems to come directly from the server, such as the series information. But I would have thought that if the server were supplying the author name then it would match the name shown on the website, so maybe it is updates some metadata from the kepub file after download?
I haven't noticed any strange names for my kepubs, so far they have been consistent with the epubs. Part of the reason for my belief in this is that Kobo are populating the database for recommendations and no for archived books. Both have no file on the device, so the info has to come from elsewhere.
Quote:
I know Kobo are updating the series information on their books bit by bit, but it does seem a bit haphazard. Some series have only one book (not always the first) with series information, others have different series names for books in the same series, and many have the series information duplicated in the title or subtitle. It would be a real mess if we didn't have Calibre to sort it all out :-)
I have a series of books that Kobo think belong in three different series. I can sort of see why because to two of them are in a sub-series, but the name of the sub-series is slightly different for each. I'll have to check in case they came from different publishers. That could explain some discrepancies.
Quote:
That might work, but I don't want to sideload any kepubs if I can possibly avoid it, it seems like that would open the way for a lot more things going wrong. I'll stick to the method of updating the database, and just try to avoid changing anthing that affects the interaction between device and server.
No, it won't work. Or at least not in the way you want it to. If you try to sideload a downloaded kepub, it isn't seen as the same book. For one thing, it will need an extension added to the file name. And anything not downloaded that is in the .kobo/kepub directory is ignored. And I think if they have DRM, they won't be read at all.
davidfor is offline   Reply With Quote
Old 03-25-2013, 03:10 AM   #9
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Quote:
Originally Posted by davidfor View Post
I haven't noticed any strange names for my kepubs, so far they have been consistent with the epubs. Part of the reason for my belief in this is that Kobo are populating the database for recommendations and no for archived books. Both have no file on the device, so the info has to come from elsewhere.
Here is an example: http://www.kobobooks.com/ebook/A-Bet...DbQ/page1.html

I got this one as a recommendation after I bought the first book in the series. The author's name on the recommendation was "Daniel Abraham". But after buying and downloading the kepub the name on the actual book shows "Abraham, Daniel", same as the epub.
GeoffR is offline   Reply With Quote
Old 03-25-2013, 06:06 AM   #10
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,907
Karma: 47303748
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by GeoffR View Post
What's going on here? Another book that you Kiwi's can buy that Kobo don't want to sell in Oz.
Quote:
I got this one as a recommendation after I bought the first book in the series. The author's name on the recommendation was "Daniel Abraham". But after buying and downloading the kepub the name on the actual book shows "Abraham, Daniel", same as the epub.
OK, I don't have one like that. That's an annoying inconsistency in the metadata.
davidfor is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Glo Virtual kepub Books? LMF Kobo Reader 14 01-23-2013 06:12 AM
Correcting 'll' errors (al , final y, etc) flameproof ePub 5 05-10-2012 08:44 AM
Correcting Ebooks newlaza Reading and Management 2 05-19-2011 05:57 AM
SAve Location after correcting the metadata Jona Calibre 4 01-06-2011 07:31 PM
best program for correcting typos / spelling in epub & mobi books ? cybmole Calibre 15 11-16-2010 06:22 AM


All times are GMT -4. The time now is 02:51 AM.


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