Guest - Testers are needed for the reworked CDateTime core component. See... https://forum.kodi.tv/showthread.php?tid=378981 (September 29) x
v19 Local characters does not sorts properly since 19.x
#1
Hi team,
Since Kodi was based on Phyton, I have problem with the local characters sorting.
I'm Swede and the letters å, ä, ö (ÅÄÖ) are rather common.

Now å and ä are sorted as a, and ö are sorted as o. The same goes for the major characters Å Ä Ö.
The proper way is this: abcdefghijklmnopqrstuvwxyzåäö
The ascii-codes for the letters isn't logical either...

The behavior is the same if I try another skin in Kodi or not.
And it same behavior KODI running on Linux, LibreElec (RPI), not tested Windows.

This is most annoying, because I try to match the list of movies from Kodi to match list from explorer in Windows / Linux.

If there is a fix I would be most greatfull.
Otherwise I hope it might be fixed soon.

best regards
Bo Schöllin
Reply
#2
Would like you to post a log with debug logging enabled in Kodi to paste.kodi.tv to confirm your platform/system.  In general Kodi will attempt to use collation (sorting) from platform Locale facet, but on some platforms falls back to a generic "C" locale and collation is done within Kodi.  Kodi collation I don't think sorts the way you want.

There's a PR for Kodi 20 development to use ICU collation on Android.

There's also issues when MySQL db is used instead of default SQlite.

scott s.
.
Reply
#3
Hi Scott,
Thanks for your answear.

Sorry, I'm acctually bodozer. I couldn't login to the forum, so I had to create a new user - bobrink.

Is there a kodi-guide to install SQlite on linux?
I just reinstalled Linux Mint with MySQL and Kodi 19.5 from scratch.
The problem remains, so I want to unistalll mySQL and install SQlite instead.

best regards
bodozer / bobrink
Reply
#4
(2023-01-13, 15:41)bobrink Wrote: The problem remains, so I want to unistalll mySQL and install SQlite instead.

No need to uninstall MySQL. Also SQLite is supported in Kodi internally by default.

There are also database tools such as SQLite Browser you can install if you want to 'inspect' SQLite database files:
python:
sudo apt install sqlite3 sqlitebrowser
Reply
#5
Thanks for the response, but still confused:

To clarify, I would like to have the satellites and the master synchronized so I only have to add new contents at the master, and the benefit that all units know seen/unseen status at my movies. I not interested to have WEB access to the Kodi database…

Under examples at this page: https://kodi.wiki/view/Advancedsettings.xml I found:

2) Configure a database for an SQLite database:
<musicdatabase>
  <type>sqlite3</type>
  <host>/usr/local/share/kodi/databases</host>
</musicdatabase>


My advancedsettings.xml file are the same at the masters and the satellites as well...
...containing following lines:
  <videodatabase>
    <type>mysql</type>
    <host>192.168.0.8</host>
    <port>3306</port>
    <user>kodibase</user>
    <pass>kodibase</pass>
  </videodatabase>


Is there a wiki how to configure SQLite for this purpose?

best regards
Bodozer
Reply
#6
(2023-01-14, 20:32)bodozer Wrote: 2) Configure a database for an SQLite database:

Wrong... Kodi uses SQLite files by default. So no need to add any lines in the advancedsettings.xml file, you can only add the usage for MySQL/MariaDB server support.
Reply
#7
Sorry, the problem remain...

When using the MySQL database settings I described, the swedish letters Å, Ä and Ö is listed wrong.
Without the  MySQL database settings the movies are listed correct.
I do really need the database sharing feature...

Can I some way have any use of SQLite settings to correct the problem above?
Otherwise, is there, any other sollution?

regards
bodozer
Reply
#8
If you want a shared database your only options are MySQL or MariaDB.  I encourage you to take a look at Kodi 20.0.   In Kodi, sorting is mainly done in Kodi itself.  The sort order (collation) is determined by the locale setting on your system, except for Android Kodi wasn't able to use the standard C language libraries due to Android restrictions and so would default to the so-called "C" locale.  I'm not sure if there are any changes in Kodi 20.0 for that (I don't do Android).  If you turn on debug logging in Kodi it will log what locale is in use.  That should be your first step.

scott s.
.
Reply
#9
Hi Scott,

I found that I alreday have a kodi.log file.
I entered it at paste.kodi.tv.
And I found following at line 310: global locale set to sv_SE.UTF-8
Do you have access to that info?
If so, can you see something else that's fault or missing?

I also found this issue with mySQL:
https://nerdia.net/2018/05/30/mysql-not-...ct-solved/
They recommend following part COLLATE utf8_swedish_ci to the ORDER string when retrieve info from MySQL.
Assuming that is no setting I can set, orHuh

regards,
bodozer
Reply
#10
OK it looks like Kodi is correctly setting your locale so it should be using the sorting order of your OS.  I don't see a link to your pasted log so can't check that.  It is not possible to change the database collation used by Kodi.

scott s.
.
Reply
#11
Hi Scott,

Did you see the link to the mySQL problem?
If its a bug, is too late to fix it for Kodi 20.0?

br
bodozer
Reply

Logout Mark Read Team Forum Stats Members Help
Local characters does not sorts properly since 19.x0