![]() |
#1 |
Junior Member
![]() Posts: 8
Karma: 54
Join Date: Sep 2010
Device: Kindle
|
How to fix author sort for Kindle
I had a number of books in Calible from Baen free library that had bad author data or even no author data when pushed to the Kindle. Even after updating meta data in Calibre it wasn't right on the Kindle. The problem is that the Calibre metadata isn't used by the Kindle, it uses the author field in the MOBI file. Its author sort uses expects the string to be in the format "lastname, firstname" (not the space after the comma needs to be there).
I tried using Calibre to convert my books from PRC to MOBI and that helped the ones with no author at all on the Kindle but now the sort order was wrong. I had the Calibre author name set as "Firstname lastname" and author sort as "lastname, firstname". The trick was in checking what was in the MOBI files using the reader window in Calibre and viewing the book properties. It had the MOBI author field as "firstname lastname". I then re-ran the conversion to MOBI and set the "Use author sort for author" checkbox in the mobi output properties. This caused the MOBI file to have "lastname, firstname" for the author property in the MOBI files and now they worked on the Kindle. Kindle will take a MOBI book with author set to "lastname, firstname" and show it in the list as "firstname lastname" but still sort by lastname. I then discovered that the Baen files that came as MOBI format were not sorting to the same location as the converted files. Checking these I found the author in the wrong format. You can select files in calibre and tell it to convert to the format they are already in. You get a warning but it will do it anyway. I ran all the rest of my books through this and now all the single author books sort correctly on the Kindle. FYI, you can mass edit the meta data and check to the 'automatically set author sort' field to get the standard name conversion. The last problem is with multiple author books. The auto set author sort above was converting "David Weber & Eric Flint" to "Weber, David & Flint, Eric". This would sort properly on the Kindle but the display on the book list would show "David & Flint, Eric Weber". I.e. it was expecting a 'lastname, firstname' format, finding the comma and switching the two substrings around. To get around this you can manually change the author sort from "Weber, David & Flint, Eric" to "Weber, David" but that is all that will show up on the Kindle. I haven't figured out a way to have multiple authors show up correctly and sort correctly. FYI, after pushing the modified MOBI files with the proper author names I had to reset the Kindle to get them to work right. I guess the Kindle caches book information on startup and needs the reset to force it to re-read that. |
![]() |
![]() |
![]() |
#2 |
Junior Member
![]() Posts: 8
Karma: 54
Join Date: Sep 2010
Device: Kindle
|
A followup on mulitple authors. If you set the author sort field to "Weber, David;Flint, Eric" it will sort properly and show on the Kindle as "David Weber and Eric Flint". Note there is NO space after the semi-colon but there MUST be a space after the commas.
There is a minor problem in Calibre with the conversion. Checking the MOBI file properties will show the author field as "Weber, David;Flint, Eric;Weber, David;Flint, Eric". I don't know if this is a display error in the Calibre viewer or what. It would be nice if a Calibre developer added a feature/preference to the 'automatically set author sort' option to use the semi-colon format instead of the ampersand format it uses now. An even better feature would be to allow editing of the metadata in the MOBI file so we don't have to run a book conversion just to update the metadata in the actual file. This would be the reverse of the feature in the edit metadata dialog that can copy the MOBI metadata into the Calibre metadata fields. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Sep 2010
Device: Kindle 3
|
I just registered to add my voice to this issue.
Selecting the "Set author_sort as author" (paraphrased) option and then re-sending my books to the Kindle (despite not being converted -- maybe that option documentation should change) does fix the sorting. However, the Kindle struggles on multiple authors separated by an ampersand as described above. For example, if author -> "J. R. R. Tolkien & Christopher Tolkien" author_sort -> "Tolkien, J. R. R. & Tolkien, Christopher" and the option is ticked for using author_sort for author on Mobi formats, then on the Kindle it is displayed as: "J. R. R. & Tolkien, Christopher Tolkien" Any suggestions or advice? Last edited by Jessehk; 09-14-2010 at 07:56 AM. |
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Adding a tweak to change how automatic author sorting works is doable. Open a ticket for it. But I would urge you not to do it. calibre has a normalized format for representing multiple authors in strings. This format was arrived at after extensive debate. Do not cripple the metadata in your library just to satisfy the Kindle's limitations.
|
![]() |
![]() |
![]() |
#5 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,251
Karma: 3720310
Join Date: Jan 2009
Location: USA
Device: Kindle, iPad (not used much for reading)
|
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,911
Karma: 7076137
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Yesterday I took some time to look at this issue. I don't have a kindle, and was defeated by Kindle for PC.
What I found: If you uncheck the Use Author Sort... box, then when you send a .mobi to a device, calibre will reformat the authors in the mobi to be 'author 1;author 2'. If my authors are Joe Blogs & Sally Texts, then the resulting book contained 'Joe Blogs;Sally Texts'. Kindle for PC displayed that as 'Joe Blogs and Sally Texts'. This seems right. However, when I checked the Use Author Sort, calibre didn't process the authors list in the same way. It used the author sort unchanged, not separating individual author_sort strings with ';' like it does for author. This behavior is arguably a bug (although there are cases where it isn't). I think it works this way because at the time the mobi code was written, we didn't have individual author sort strings. We do now, so I tried changing it (and succeeded). WIth my change, the book's author contained 'Blogs, Joe;Texts, Sally'. I then opened that book in Kindle for PC, *and it ignored me*. It carefully changed my authors from LN, FN to FN LN! Just in case I was doing something silly, I changed the code to put XXX in front of every author's last name during the send to device, and Kindle for PC showed me Joe XXXBlogs. In all cases it sorted under Joe. What is the point of sending author_sort if the kindle just turns it back around when it displays it (I hate that), and sorts it by the first name? That is what Kindle for PC does. I couldn't find an option to cause it to behave reasonably. At this point I gave up and tossed my changes into the trash can. Going further isn't worth anything to me, because the only program I have that cares undoes the work. Perhaps the real Kindle behaves differently? I have no idea, but Isherwood's post strongly implies that it converts Blogs, Joe to Joe Blogs. If so, I don't see the point of using author_sort instead of author. Perhaps some other developer with a Kindle would understand the point, and be willing to do the work. |
![]() |
![]() |
![]() |
#7 | |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Sep 2010
Device: Kindle 3
|
Quote:
|
|
![]() |
![]() |
![]() |
#8 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,911
Karma: 7076137
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
My question is why bother to use the option when after a 'fix', the Kindle apparently produces the same result as when the option is off? As a developer, it is hard to get excited about doing work that has null result. I would rather disable the option.
|
![]() |
![]() |
![]() |
#9 | |
Junior Member
![]() Posts: 5
Karma: 10
Join Date: Sep 2010
Device: Kindle 3
|
Quote:
On the Kindle, for an author string of "Last, First", it will display "First Last" but sort by "Last". On Calibre, Author is "First Last" and author_sort is often "Last, First". Therefore, the option sets Author to be author_sort so that it is correctly interpretted by the Kindle. If this option is NOT selected, then Kindle displays the author correctly, but sorts by "First" instead of "Last". The option works as advertised (and does correct the sorting problem) except when there are multiple authors involved. I am under the impression from you post (though I'm not sure myself) that Calibre automatically converts multiple authors to use a semicolon instead of an ampersand when sending *.mobi books to the Kindle (because this is what Kindle understands) but that it doesn't do this when the option to use author_sort as author is set (instead, keeping the ampersand, which the Kindle doesn't understand). To me, that sounds like a bug. But, as I said, I could very well be mistaken. Thanks for your continued interest. ![]() |
|
![]() |
![]() |
![]() |
#10 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,911
Karma: 7076137
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Quote:
K4PC displays First Last and sorts First Last, making the option useless. I will look at the code again later this week, when life permits. Out of curiosity, if the kindle is given 'Last, First', is there no way to make it display Last, First? It switching them back to First Last would drive me crazy. I went to a lot of trouble to ensure all authors in my library are entered Last, First, and I want to see them that way. Hmmm... perhaps *this* is why someone asked for a tweak to compute author_sort values without the comma, as in 'Last First'. |
|
![]() |
![]() |
![]() |
#11 |
Junior Member
![]() Posts: 8
Karma: 54
Join Date: Sep 2010
Device: Kindle
|
In the original post, I noted (but may not have been clear) that if you have the book already on the kindle and change the metadata and push the new version down, the kindle doesn't show a change. It is caching the metadata it reads from the mobi files at startup. To get it to recognize the change you have to restart the kindle. I would expect the kindle for pc program has the same issue. This is probably why you weren't seein the changes when you tried different things
When the mobi file author field (use the viewer 'metadata' button to see what is in the mobi file, not what is in the calibre metadata database) contains "lastname, firstname" it will display as "firstname lastname" but sort by lastname. There must be a space after the comma according to other posts I saw. I have tested that "lastname1, firstname1;lastname2, firstname2" will display as "firstname1 lastname1 and firstname2 lastname2" and sort by lastname1. Addressing another posters issue about breaking things to suit my kindle. Since I have told calibre that the output device was a kindle, it could have a conversion from the 'standard' multi author format into 'kindle' multi author format happen when pushing the books. The biggest change I would like to see is a way to update the metadata in the mobi file without having to do a 'mobi to mobi' conversion. If my calibre stored file is already in mobi format, it just pushes the file to the kindle without conversion and doesn't use the calibre metadata anywhere. If i was sending a non-mobi file to the kindle, calibre would convert it and set the proper metadata. Perhaps there should be an option when pushing books already in the right format to do a mini-convert just to update the metadata without having to convert the entire book. It takes about 2 hours on a fast pc to convert 300+ books just to update metadata. |
![]() |
![]() |
![]() |
#12 |
Junior Member
![]() Posts: 8
Karma: 54
Join Date: Sep 2010
Device: Kindle
|
Another thing to watch out for when changing author fields and re-pushing a book is that Calibre pushes them into a folder using the author sort field. Therefore if you change that and re-push the book, the new one goes into a different folder. You now have 2 copies on the device that sort to different locations.
|
![]() |
![]() |
![]() |
#13 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,269
Karma: 23661992
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
calibre updates metadata in mobi files when you send them to the device. You dont need to convert to update metadata unless your files are actually a very old version of MOBI
|
![]() |
![]() |
![]() |
#14 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,911
Karma: 7076137
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
As promised, I have looked at the code, and thought about what role I am willing to play here.
I have decided not to attempt to make these changes. Reason: The problem has complexities that make it non-trivial to solve. I do not have a kindle and do not use the .mobi format, so I have no personal interest in a solution. I would rather use the time I allocate to this hobby to do things that I find useful. |
![]() |
![]() |
![]() |
#15 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,812
Karma: 26912940
Join Date: Apr 2010
Device: sony PRS-T1 and T3, Kobo Mini and Aura HD, Tablet
|
Quote:
You and Kovid are my heroes. Helen |
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Kindle, Calibre, Author sort | gdaydigger | Calibre | 5 | 03-11-2014 08:21 PM |
Kindle, Calibre and Author Sort | gdaydigger | Amazon Kindle | 7 | 09-10-2010 11:49 PM |
Author Sort & Kindle | seagull | Calibre | 0 | 12-25-2009 12:42 PM |
Author Sort | wexdan | Calibre | 2 | 10-22-2009 03:21 PM |
Author(s) & Author Sort | BobF | Calibre | 11 | 01-02-2009 05:01 PM |