Bug 19506

Summary: Staged Marc Import should warn if the selected encoding does not match MARC 21 leader
Product: Koha Reporter: Barton Chittenden <barton>
Component: MARC Bibliographic record staging/importAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: sbcornell
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:

Description Barton Chittenden 2017-10-21 19:08:30 UTC
Mis-matches between character encodings will cause diacritics be incorrectly imported into Koha. If the imported marc record is MARC8 encoded and imported as UTF-8, diacritics will be converted to the REPLACEMENT CHARACTER '�'. A UTF-8 encoded file imported as MARC8 will try to render the multi-byte UTF-8 characters as MARC8, resulting in garbage text.

MARC21 stores its encoding in leader position 09 - Character coding scheme (http://www.loc.gov/marc/bibliographic/bdleader.html). The accepted encodings are '#' for MARC8 and 'a' for UTF-8 (although Koha exports ' ' for MARC8).

Koha should check the leader for MARC21 records and warn if the selected encoding does not match the encoding of the marc record, giving the user the opportunity to change the encoding or download fresh records with the correct encoding.

[I couldn't tell if this was an issue for UNIMARC]