[MDEV-5352] tis620: Sortlen is too large Created: 2013-11-27  Updated: 2017-11-05

Status: Open
Project: MariaDB Server
Component/s: None
Affects Version/s: 5.1.67, 5.2.14, 5.5.34, 10.0.6
Fix Version/s: 10.2

Type: Bug Priority: Minor
Reporter: Alexander Barkov Assignee: Alexander Barkov
Resolution: Unresolved Votes: 0
Labels: None


 Description   

"Sortlen" reports "4" for tis620_thai_ci in this query:

mysql> show collation like 'tis620_thai_ci';
+----------------+---------+----+---------+----------+---------+
| Collation      | Charset | Id | Default | Compiled | Sortlen |
+----------------+---------+----+---------+----------+---------+
| tis620_thai_ci | tis620  | 18 | Yes     | Yes      |       4 |
+----------------+---------+----+---------+----------+---------+
1 row in set (0.00 sec)

"Sortlen" comes from the "strxfrm_multiply" member
of my_charset_tis620_thai_ci.

The code in strings/ctype-tis620.c does not really look like
the weight string for tis620_thai_ci can grow four times comparing
to the original text string. strxfrm_multiply=1 should be enough.

A too large strxfrm_multiply (Sortlen) value affects performance
of non-indexed ORDER BY negatively.


Generated at Thu Feb 08 07:03:37 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.