Bug 33134: Add some 76 missing languages
authorJanusz Kaczmarek <januszop@gmail.com>
Fri, 3 Mar 2023 22:15:51 +0000 (23:15 +0100)
committerKatrin Fischer <katrin.fischer@bsz-bw.de>
Tue, 7 May 2024 13:53:51 +0000 (15:53 +0200)
commit4053893e4f282456dbc4bdb53f14b8b4a482b71c
treeeab66948e74cbdd924898637d180fe6a00165b56
parent2a20cbb94a8e4d54279d80c136e09a29361bfcfd
Bug 33134: Add some 76 missing languages

When languages come into facets in ES, Koha should know
the names for the codes used records.  Otherwise
the three-letters language code is being displayed in
the facet instead of name.  Koha now knows about 77
languages, many are still missing.

The most missed 76 languages, in order of occurrences
in my data sets, are (MARC 21 codes): grc, syr, chu, cop, arc,
ang, epo, syc, gez, sla, san, csb, akk, gmh, egy, wen, gle,
fro, rom, mac, mal, uga, mis, sem, sux, pli, bos, che, dum,
kaz, tib, enm, frm, mlt, got, nds, ira, lin, uzb, ave, cho,
jrb, bnt, pal, tut, goh, hsb, inc, mlg, roa, cel, sam, bem,
fur, gem, hit, lad, nah, ota, peo, pro, tat, wel, yor, bra,
den, hau, her, kas, mga, myn, nya, pra, que, tir, tuk.

Plus: gwi, dgr, chp asked in bug 23693.

Here, I do not put language codes which are extremely rare
in my data sets.

Subtags and names for language_subtag_registry are taken from
https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry,
English names for language_descriptions.description - from
https://www.loc.gov/marc/languages/language_code.html, and Polish names -
from https://przepisy.bn.org.pl/aneksy#25-kody-jezykow---marc-21.

Test plan:
==========
1. Hava a ES installation with reasonable number of records,
   with a variety of languages in 008/35-39 not present in
   Koha (you can modify your record with codes from the list above).
   Set FacetMaxCount to a high number (like 500 or so,
   dependiing on the size of your data set).
2. Do a search, like '*a*'.
3. Controll the content of the Language faset -- you should
   see some bare codes instead of language names.
4. Apply the patch -- update the database.
5. Perform the same search.
6. You should see the names in place of the codes.
7. Optionally, you can activate the Polish translation and
   you should be able to see Polish names for the added languages.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
installer/data/mysql/atomicupdate/bug_33134_addMissingLanguages.pl [new file with mode: 0755]
installer/data/mysql/mandatory/subtag_registry.sql