Bug 5067 - bulkmarcimport.pl import script removes dashes in ISBN fields
Summary: bulkmarcimport.pl import script removes dashes in ISBN fields
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Command-line Utilities (show other bugs)
Version: rel_3_2
Hardware: All All
: PATCH-Sent (DO NOT USE) normal (vote)
Assignee: Frédéric Demians
QA Contact: Bugs List
URL:
Keywords:
Depends on:
Blocks: 5012
  Show dependency treegraph
 
Reported: 2010-07-28 15:21 UTC by Frédéric Demians
Modified: 2012-10-25 23:03 UTC (History)
3 users (show)

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


Attachments
Proposed patch (3.09 KB, patch)
2011-04-12 11:04 UTC, Frédéric Demians
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Frédéric Demians 2010-07-28 15:21:14 UTC
Import script shouldn't remove an information present in entering biblio records.
Comment 1 Colin Campbell 2010-07-28 19:08:32 UTC
Should it be a switchable option? There are good reasons for removing the (often erroneous) hyphens. And standard usage in marc is without the hyphens.

(NB you can generate hyphens from a un-hyphenated number using the perl module Business::ISBN)
Comment 2 Frédéric Demians 2010-07-28 21:55:42 UTC
> Should it be a switchable option? There are good reasons for removing the
> (often erroneous) hyphens. And standard usage in marc is without the hyphens.

Yes, but when you have hand crafted a biblio record file with ISBN containing hyphens you prefer not to loose them. That's interesting: MARC21 records seems to have no hyphens, you're correct, but UNIMARC records have generally hyphens in ISBN field (BNF and SUDOC) and there is EAN field for ISBN without -...

We can conclude that for MARC21 entering bibli records we don't have to remove hyphens since they shouldn't have any. And for UNIMARC records, we mustn't remove them since they are expected by the standard.

> (NB you can generate hyphens from a un-hyphenated number using the perl module
> Business::ISBN)

I already appreciate and use this very useful module. Thanks Colin for the tip.
Comment 3 Chris Cormack 2010-12-14 02:31:26 UTC
What's the current state of this patch?
Comment 4 Frédéric Demians 2010-12-14 06:29:31 UTC
> What's the current state of this patch?

Here it is:

http://lists.koha-community.org/pipermail/koha-patches/2010-December/013262.html
Comment 5 Stefano Bargioni 2011-04-12 10:17:22 UTC
In my opinion, removing dashes from ISBN must be an option.
Anyway, ISBN is a repeatable field. Currently, bulkmarcimport.pl removes dashes only from the first occurrence.
Comment 6 Frédéric Demians 2011-04-12 11:04:47 UTC
Created attachment 3892 [details] [review]
Proposed patch
Comment 7 Frédéric Demians 2011-04-12 11:07:05 UTC
> In my opinion, removing dashes from ISBN must be an option.

This is the case in my proposed patch. You just have to sign it.

> Anyway, ISBN is a repeatable field. Currently, bulkmarcimport.pl
> removes dashes only from the first occurrence.

And still the case in my patch. But it isn't a big deal to fix it.
Comment 8 Chris Cormack 2011-04-12 23:43:37 UTC
This was submitted well before the feature freeze, (December in fact) so I have pushed it, please test