Bug 13192 - Hard-coded value (ISBN Prefix '978') in cataloguing::value_builder::unimarc_field_010
Summary: Hard-coded value (ISBN Prefix '978') in cataloguing::value_builder::unimarc_f...
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: MARC Bibliographic data support (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low trivial (vote)
Assignee: Galen Charlton
QA Contact: Testopia
Depends on:
Reported: 2014-11-03 18:45 UTC by Tiburce Euphrasie
Modified: 2021-06-21 07:54 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Text to go in the release notes:
Version(s) released in:


Note You need to log in before you can comment on or make changes to this bug.
Description Tiburce Euphrasie 2014-11-03 18:45:13 UTC
Frédéric Demians suggests me to open a new bug report for this case (please read http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13167 for more information):

...I think I've also detected a small problem in cataloguing::value_builder::unimarc_field_010 :
[...] Line 94 to 96 :
    if (length ($isbn) == 13){
        $isbn = substr($isbn, 3, length($isbn)-3);
[...] Then, line 143 :
        $sth->execute($seg2, "978$seg2");

This "978" on line 143 is hard-coded and there's no relation with the original data inside $isbn (lost on line 95 via the substr function). I don't know if this is a real problem but it might be better to keep the original data than replacing it with "978".

Thanks to Frédéric Demians for resolving bug 13167.
Comment 1 Fred P 2017-03-28 17:45:24 UTC
In the United States, ISBN's starting with 979 are not yet introduced, however material in France, Europe and other countries are already rolling out 979 ISBN's. Sadly, they do not play well with Koha scripts. Let's hope we can find a solution before these codes become more prevalent.
Comment 2 Katrin Fischer 2019-02-10 10:38:14 UTC
This is still valid. I am not sure how the plugin works as there is no documentation in the code - checking ISBN validity?

I wonder why it is not using Business::ISBN?

Adding some UNIMARC people to see if this plugin is still used and should be fixed. The original developer was Nahuel who is no longer working on Koha.