Kodi Community Forum
Sort Accented characters in list - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111)
+---- Forum: OS independent / Other (https://forum.kodi.tv/forumdisplay.php?fid=228)
+---- Thread: Sort Accented characters in list (/showthread.php?tid=341255)



Sort Accented characters in list - Sinisan - 2019-02-24

Hi all,

I've got a problem since I've started to use this wonderful Kodi, but I never tried to solve it until today.

I'm French, and we have accented characters like à, é, ç (ok, it's more a special characters than an accented one, but it's the same problem Smile)

The problem is in lists (movie list, all of them in fact), this characters are sorted at the end, after all the others. For example, a movie which name starts with "à" will be sorted at the end of the list, instead of at start, with all "a" titles.

I searched on this forum but didn't find any answer (some asked but with no answer). How can I solve that ? I would like these characters be sorted as if they were normal.

This problem is with Kodi, regardless of the platform, regardless of the skin. I have to say that a SQL request on the Kodi database gives a correct answer.

Thank you for your help Smile


RE: Sort Accented characters in list - DaveBlake - 2019-02-24

Sorry but there is mot wayto get Kodi to do this. It does its own sorting in memory (a version of natural sort) internally and accent chars end up where they do. I hope that one day the sorting will be done in the db and collation will be configurable, but it isn't now.


RE: Sort Accented characters in list - Sinisan - 2019-02-24

(2019-02-24, 10:46)DaveBlake Wrote: Sorry but there is mot wayto get Kodi to do this. It does its own sorting in memory (a version of natural sort) internally and accent chars end up where they do. I hope that one day the sorting will be done in the db and collation will be configurable, but it isn't now.
 Dear @DaveBlake , thank you very much for your answer. First, it means you understood my problem, despite of my poor English language skill Smile

More seriously, with your answer I know now it's wasted time to try to find something to set up in Kodi.

In addition, perhaps it could help other people if they want the same thing as me. I used a "side way" to correct this, using SQL directly :
- I copied all titles from c00 to c10, which is the field used, when not empty, to sort by Kodi
- In this field c10, I replaced all "accented characters" to "normal characters". For example, "ç" to "c", "à" to "a", "À" to "A"...

All with very simple SQL request. It's ok like that.

Of course, unfortunately, this solution needs to be done each time I add a new movie, but it's better than nothing. Perhaps could I do a script with all requests (an add-on ?) than I run automatically, but I don't know how to do that Smile 

Thank you once again, and I hope Kodi will include non-english people in the next update Smile Smile


RE: Sort Accented characters in list - ThomB - 2021-03-07

Hello @Sinisan,

I found your thread so I thought you might be interested in knowing that this PR solved the issue you described: https://github.com/xbmc/xbmc/pull/17562 Smile
It should be in Matrix (but I'm not able to confirm this yet).


RE: Sort Accented characters in list - scott967 - 2021-03-08

This issue https://github.com/xbmc/xbmc/issues/15125 give a good synopsis of collation for Kodi on Android.

scott s.
.