Argument "01e" isn't numeric in numeric ne (!=) at /home/vagrant/kohaclone/cataloguing/addbiblio.pl line 507.
Created attachment 77544 [details] [review] Bug 21172: Remove warning from addbiblio.pl Argument "01e" isn't numeric in numeric ne (!=) at /home/vagrant/kohaclone/cataloguing/addbiblio.pl line 507. A tagfield can be 01e and so raise a warning is compared with == or != This patch also fixes few inconsistencies: - tagfield for items.itemnumber must be retrieved with GetMarcFromKohaField (to support other marcflavours) - do not use $_ - loop only once on $usedTagsLib Test plan: For devs only, read the code and confirm the changes make sense.
Isn't 01e a bug on the data?
(In reply to Tomás Cohen Arazi from comment #2) > Isn't 01e a bug on the data? Maybe, maybe not, who really knows? :) "01e" site:http://irc.koha-community.org will return stuffs like: 09:55 magnusenger Is it just me, or does a MARC21 tag called 01e look a little odd? 10:02 drojf oh that 01e coded field error thing in the marc frameworks is actually supposed to be there? i always thought that was a misspelled 019 :D 11:09 gmcharlt magnusenger: it's not standard MARC21; it's a custom field that was once used by the RLIN bibliographic utlity 18:46 tcohen i've just noticed we don't have it, but have '01e' instead 18:46 tcohen is field 019 of any use in MARC21? Then: http://irc.koha-community.org/koha/2013-07-16 http://irc.koha-community.org/koha/2012-11-21 etc.
(In reply to Tomás Cohen Arazi from comment #2) > Isn't 01e a bug on the data? I was curious about this... https://www.loc.gov/marc/bibliographic/bdintro.html "Variable fields - The data in a MARC bibliographic record is organized into variable fields, each identified by a three-character numeric tag that is stored in the Directory entry for the field. Each field ends with a field terminator character. The last variable field in a record ends with both a field terminator and a record terminator (ASCII 1D hex). There are two types of variable fields." It seems that technically 01e is a violation of the MARC standard. Maybe it is time to remove 01e from the frameworks...
Created attachment 88092 [details] [review] Bug 21172: Remove warning from addbiblio.pl Argument "01e" isn't numeric in numeric ne (!=) at /home/vagrant/kohaclone/cataloguing/addbiblio.pl line 507. A tagfield can be 01e and so raise a warning is compared with == or != This patch also fixes few inconsistencies: - tagfield for items.itemnumber must be retrieved with GetMarcFromKohaField (to support other marcflavours) - do not use $_ - loop only once on $usedTagsLib Test plan: For devs only, read the code and confirm the changes make sense. Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Comment on attachment 88092 [details] [review] Bug 21172: Remove warning from addbiblio.pl Review of attachment 88092 [details] [review]: ----------------------------------------------------------------- ::: cataloguing/addbiblio.pl @@ +490,5 @@ > my %seen; > my @tab_data; # all tags to display > + > + my $max_num_tab=-1; > + my ( $itemtag, $itemsubfield ) = GetMarcFromKohaField( "items.itemnumber", scalar $input->param('frameworkcode') ); Second param is not needed, now the default framework is taken as authoritative for marc to koha mappings.
Otherwise looking good for me, marc21 standard does not allow non numeric tags, but sometimes it happens and Koha should count with this
Created attachment 88117 [details] [review] Bug 21172: Remove warning from addbiblio.pl Argument "01e" isn't numeric in numeric ne (!=) at /home/vagrant/kohaclone/cataloguing/addbiblio.pl line 507. A tagfield can be 01e and so raise a warning is compared with == or != This patch also fixes few inconsistencies: - tagfield for items.itemnumber must be retrieved with GetMarcFromKohaField (to support other marcflavours) - do not use $_ - loop only once on $usedTagsLib Test plan: For devs only, read the code and confirm the changes make sense. Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Created attachment 88118 [details] [review] Bug 21172: Remove obsolete framework parameter from GetMarcFromKohaField
Happy to see this old warning go away. I provided a follow-up to fix Josef's concern. I noticed there are still a lot of calls with the framework parameter even if it has no effect. Something to fix separately at some point.
Awesome work all! Pushed to master for 19.05
Pushed to 18.11.x for 18.11.05
backported to 18.05.x for 18.05.13
(In reply to David Cook from comment #4) > It seems that technically 01e is a violation of the MARC standard. > > Maybe it is time to remove 01e from the frameworks... See bug 24274