Koha/misc
Nick Clemens c7eb047126 Bug 28352: Only check authorised values mapped to DB fields
The errors reported seem to be caused by authorised values mapped to MARC fields
but not mapped to a koha field.

We should additionally make sure to check the Default framework

Also, adding comment to indicate we only check records with items, because we do

TO test:
1 - In a framework that is not the default map a MARC field to an authorised value, but not a koha field
2 - In SQL, force the kohafield to NULL for the mapping you just make
    UPDATE marc_subfield_structure SET kohafield = NULL WHERE frameworkcode='BKS' and authorised_value='HINGS_AS'
3 - perl misc/maintenance/search_for_data_inconsistencies.pl
4 - get the following errors:
Use of uninitialized value $tmp_kohafield in pattern match (m//) at /kohadevbox/koha/misc/maintenance/search_for_data_inconsistencies.pl line 151.
Use of uninitialized value $tmp_kohafield in substitution (s///) at /kohadevbox/koha/misc/maintenance/search_for_data_inconsistencies.pl line 154.
Can't call method "get_column" on an undefined value at /kohadevbox/koha/misc/maintenance/search_for_data_inconsistencies.pl line 157.
5 - Apply patch
6 - Repeat
7 - No more errors

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2021-10-01 16:28:55 +02:00
..
admin Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
bin Bug 17600: Fix POSIX imports 2021-07-29 14:37:26 +02:00
cronjobs Bug 29076: Fetch the zebraqueue entries when not confirm 2021-09-28 15:12:44 +02:00
devel Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
interface_customization
load_testing Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
maintenance Bug 28352: Only check authorised values mapped to DB fields 2021-10-01 16:28:55 +02:00
migration_tools Bug 17600: (follow-up) Fix missing C4::AuthoritiesMARC import 2021-07-30 08:06:07 +02:00
release_notes
search_tools Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
translator Bug 17600: Remove wrong C4::Context imports 2021-09-20 14:44:27 +02:00
add_date_fields_to_marc_records.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
background_jobs_worker.pl Bug 23678: Allow cancel holds in bulk 2021-10-01 16:02:58 +02:00
batchCompareMARCvsFrameworks.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
batchdeletebiblios.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
batchDeleteUnusedSubfields.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
batchImportMARCWithBiblionumbers.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
batchRebuildBiblioTables.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
batchRebuildItemsTables.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
batchRepairMissingBiblionumbers.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
check_sysprefs.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
commit_file.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
export_borrowers.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
export_records.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
exportauth.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
import_patrons.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
koha-install-log
kohalib.pl
link_bibs_to_authorities.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
load_yaml.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
mod_zebraqueue.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
perlmodule_ls.pl
perlmodule_rm.pl
recreateIssueStatistics.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
sax_parser_print.pl
sax_parser_test.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
sip_cli_emulator.pl
stage_file.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00
z3950_responder.pl Bug 17600: Standardize our EXPORT_OK 2021-07-16 08:58:47 +02:00