Bug 20245: Wrong language code for Slovak
authorRadek Šiman <rbit@rbit.cz>
Thu, 8 Mar 2018 21:28:37 +0000 (22:28 +0100)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Tue, 24 Apr 2018 14:30:47 +0000 (11:30 -0300)
This patch updates iso639_2_code value for Slovak language

Test plan:
1) Obtain a biblio record having 'slo' value in its language
   code (marc field 041a)
2) Try to find it through Advanced search + more options
   with language set to Slovak
3) Nothing is found
4) Apply this patch
5) Repeat steps 1 and 2
6) Record is found now

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

installer/data/mysql/atomicupdate/bug_20245-update_slovak-language-code.sql [new file with mode: 0644]
installer/data/mysql/mandatory/subtag_registry.sql

diff --git a/installer/data/mysql/atomicupdate/bug_20245-update_slovak-language-code.sql b/installer/data/mysql/atomicupdate/bug_20245-update_slovak-language-code.sql
new file mode 100644 (file)
index 0000000..871f5f0
--- /dev/null
@@ -0,0 +1 @@
+UPDATE language_rfc4646_to_iso639 SET iso639_2_code = 'slo' WHERE iso639_2_code = 'slk' AND rfc4646_subtag = 'sk';
index ebcdedc..87858d7 100755 (executable)
@@ -922,7 +922,7 @@ INSERT INTO language_subtag_registry( subtag, type, description, added)
 VALUES ( 'sk', 'language', 'Slovak','2014-10-30');
 
 INSERT INTO language_rfc4646_to_iso639(rfc4646_subtag,iso639_2_code)
-VALUES ( 'sk','slk');
+VALUES ( 'sk','slo');
 
 INSERT INTO language_descriptions(subtag, type, lang, description)
 VALUES ( 'sk', 'language', 'sk', 'Slovenčina');