From d0d85a690f450a4fd1812ab9404bce85d19f6559 Mon Sep 17 00:00:00 2001 From: Ere Maijala Date: Mon, 5 Nov 2018 14:22:01 +0200 Subject: [PATCH] Bug 11529: Add new fields to biblio table Signed-off-by: Michal Denar Signed-off-by: Michal Denar --- C4/Biblio.pm | 20 ++++-- .../data/mysql/atomicupdate/bug_11529.perl | 34 +++++++++ .../mandatory/marc21_framework_DEFAULT.sql | 6 +- .../mandatory/marc21_framework_DEFAULT.sql | 6 +- .../mandatory/marc21_framework_DEFAULT.sql | 6 +- .../obligatoire/marc21_framework_DEFAULT.sql | 2 +- .../Obligatoire/marc21_framework_DEFAULT.sql | 6 +- .../marc21_simple_bib_frameworks.sql | 44 ++++++------ .../mandatory/marc21_framework_DEFAULT.sql | 6 +- installer/data/mysql/kohastructure.sql | 8 +++ .../mandatory/marc21_framework_DEFAULT.sql | 6 +- .../normarc/Obligatorisk/normarc.sql | 6 +- .../mandatory/marc21_framework_DEFAULT.sql | 6 +- .../marc21_bibliographic_DEFAULT_general.sql | 6 +- .../marc21_bibliographic_DEFAULT_general.sql | 6 +- t/db_dependent/Biblio.t | 69 +++++++++++++++++-- 16 files changed, 174 insertions(+), 63 deletions(-) create mode 100644 installer/data/mysql/atomicupdate/bug_11529.perl diff --git a/C4/Biblio.pm b/C4/Biblio.pm index d7c749144b..472a33806b 100644 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -2940,6 +2940,10 @@ sub _koha_add_biblio { SET frameworkcode = ?, author = ?, title = ?, + subtitle = ?, + medium = ?, + part_number = ?, + part_name = ?, unititle =?, notes = ?, serial = ?, @@ -2950,8 +2954,10 @@ sub _koha_add_biblio { "; my $sth = $dbh->prepare($query); $sth->execute( - $frameworkcode, $biblio->{'author'}, $biblio->{'title'}, $biblio->{'unititle'}, $biblio->{'notes'}, - $biblio->{'serial'}, $biblio->{'seriestitle'}, $biblio->{'copyrightdate'}, $biblio->{'abstract'} + $frameworkcode, $biblio->{'author'}, $biblio->{'title'}, $biblio->{'subtitle'}, + $biblio->{'medium'}, $biblio->{'part_number'}, $biblio->{'part_name'}, $biblio->{'unititle'}, + $biblio->{'notes'}, $biblio->{'serial'}, $biblio->{'seriestitle'}, $biblio->{'copyrightdate'}, + $biblio->{'abstract'} ); my $biblionumber = $dbh->{'mysql_insertid'}; @@ -2983,6 +2989,10 @@ sub _koha_modify_biblio { SET frameworkcode = ?, author = ?, title = ?, + subtitle = ?, + medium = ?, + part_number = ?, + part_name = ?, unititle = ?, notes = ?, serial = ?, @@ -2995,8 +3005,10 @@ sub _koha_modify_biblio { my $sth = $dbh->prepare($query); $sth->execute( - $frameworkcode, $biblio->{'author'}, $biblio->{'title'}, $biblio->{'unititle'}, $biblio->{'notes'}, - $biblio->{'serial'}, $biblio->{'seriestitle'}, $biblio->{'copyrightdate'} ? int($biblio->{'copyrightdate'}) : undef, $biblio->{'abstract'}, $biblio->{'biblionumber'} + $frameworkcode, $biblio->{'author'}, $biblio->{'title'}, $biblio->{'subtitle'}, + $biblio->{'medium'}, $biblio->{'part_number'}, $biblio->{'part_name'}, $biblio->{'unititle'}, + $biblio->{'notes'}, $biblio->{'serial'}, $biblio->{'seriestitle'}, $biblio->{'copyrightdate'} ? int($biblio->{'copyrightdate'}) : undef, + $biblio->{'abstract'}, $biblio->{'biblionumber'} ) if $biblio->{'biblionumber'}; if ( $dbh->errstr || !$biblio->{'biblionumber'} ) { diff --git a/installer/data/mysql/atomicupdate/bug_11529.perl b/installer/data/mysql/atomicupdate/bug_11529.perl new file mode 100644 index 0000000000..43ef42f0ec --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_11529.perl @@ -0,0 +1,34 @@ +$DBversion = 'XXX'; # will be replaced by the RM +if( CheckVersion( $DBversion ) ) { + if( !column_exists( 'biblio', 'subtitle' ) ) { + $dbh->do( "ALTER TABLE biblio ADD COLUMN medium LONGTEXT AFTER title" ); + $dbh->do( "ALTER TABLE biblio ADD COLUMN subtitle LONGTEXT AFTER medium" ); + $dbh->do( "ALTER TABLE biblio ADD COLUMN part_number LONGTEXT AFTER subtitle" ); + $dbh->do( "ALTER TABLE biblio ADD COLUMN part_name LONGTEXT AFTER part_number" ); + + $dbh->do( "ALTER TABLE deletedbiblio ADD COLUMN medium LONGTEXT AFTER title" ); + $dbh->do( "ALTER TABLE deletedbiblio ADD COLUMN subtitle LONGTEXT AFTER medium" ); + $dbh->do( "ALTER TABLE deletedbiblio ADD COLUMN part_number LONGTEXT AFTER subtitle" ); + $dbh->do( "ALTER TABLE deletedbiblio ADD COLUMN part_name LONGTEXT AFTER part_number" ); + } + + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.subtitle' WHERE kohafield='bibliosubtitle.subtitle'" ); + + my $marcflavour = C4::Context->preference('marcflavour'); + + if ( $marcflavour eq 'UNIMARC' ) { + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.medium' WHERE frameworkcode='' AND tagfield='200' AND tagsubfield='b'" ); + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.subtitle' WHERE frameworkcode='' AND tagfield='200' AND tagsubfield='e'" ); + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.part_number' WHERE frameworkcode='' AND tagfield='200' AND tagsubfield='h'" ); + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.part_name' WHERE frameworkcode='' AND tagfield='200' AND tagsubfield='i'" ); + } else { + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.medium' WHERE frameworkcode='' AND tagfield='245' AND tagsubfield='h'" ); + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.subtitle' WHERE frameworkcode='' AND tagfield='245' AND tagsubfield='b'" ); + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.part_number' WHERE frameworkcode='' AND tagfield='245' AND tagsubfield='n'" ); + $dbh->do( "UPDATE marc_subfield_structure SET kohafield='biblio.part_name' WHERE frameworkcode='' AND tagfield='245' AND tagsubfield='p'" ); + } + + # Always end with this (adjust the bug info) + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 11529 - Add medium, subtitle and part information to biblio table)\n"; +} diff --git a/installer/data/mysql/de-DE/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql b/installer/data/mysql/de-DE/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql index 45a94b86dc..9e73bcdbf5 100644 --- a/installer/data/mysql/de-DE/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/de-DE/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql @@ -1066,7 +1066,7 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', '6', 'Verknüpfung', 'Verknüpfung', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Feldverknüpfung und Reihenfolge', 'Feldverknüpfung und Reihenfolge', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Titel', 'Titel', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Zusatz zum Titel', 'Zusatz zum Titel', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Zusatz zum Titel', 'Zusatz zum Titel', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Verfasserangabe etc.', 'Verfasserangabe etc.', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section/part/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -1074,8 +1074,8 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', 'g', 'Zeitabschnitt', 'Zeitabschnitt', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Zählung des Teils/der Abteilung eines Werkes', 'Zählung des Teils/der Abteilung eines Werkes', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Titel eines Teils/einer Abteilung eines Werkes', 'Titel eines Teils/einer Abteilung eines Werkes', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Zählung des Teils/der Abteilung eines Werkes', 'Zählung des Teils/der Abteilung eines Werkes', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Titel eines Teils/einer Abteilung eines Werkes', 'Titel eines Teils/einer Abteilung eines Werkes', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Das Unterfeld gibt die Institution an, auf die sich das Feld bezieht', 'Das Unterfeld gibt die Institution an, auf die sich das Feld bezieht', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Verknüpfung', 'Verknüpfung', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/en/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql b/installer/data/mysql/en/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql index a97496eec5..85d3c7da31 100644 --- a/installer/data/mysql/en/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/en/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql @@ -1072,7 +1072,7 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc.', 'Statement of responsibility, etc.', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -1080,8 +1080,8 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/es-ES/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql b/installer/data/mysql/es-ES/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql index fdf4e6632b..2fc830a0c8 100644 --- a/installer/data/mysql/es-ES/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/es-ES/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql @@ -1037,7 +1037,7 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', '6', 'Enlace', 'Enlace', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Enlace entre campo y número de secuencia', 'Enlace entre campo y número de secuencia', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Título', 'Título', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Resto del título', 'Resto del título', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Resto del título', 'Resto del título', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Mención de responsabilidad, etc.', 'Mención de responsabilidad, etc.', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designación de sección/parte/serie (SE) [OBSOLETO]', 'Designación de sección/parte/serie (SE) [OBSOLETO]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Nombre de parte/sección/serie', 'Nombre de parte/sección/serie', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -1045,8 +1045,8 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', 'g', 'Fechas predominantes', 'Fechas predominantes', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Medio', 'Medio', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Forma', 'Forma', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Número de parte o sección de la obra', 'Número de parte o sección de la obra', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Nombre de parte o sección de la obra', 'Nombre de parte o sección de la obra', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Número de parte o sección de la obra', 'Número de parte o sección de la obra', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Nombre de parte o sección de la obra', 'Nombre de parte o sección de la obra', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Versión', 'Versión', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Institución que aplica el campo', 'Institución que aplica el campo', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Enlace', 'Enlace', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/fr-CA/marcflavour/marc21/obligatoire/marc21_framework_DEFAULT.sql b/installer/data/mysql/fr-CA/marcflavour/marc21/obligatoire/marc21_framework_DEFAULT.sql index 737d4eacd2..b73eb1c09c 100644 --- a/installer/data/mysql/fr-CA/marcflavour/marc21/obligatoire/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/fr-CA/marcflavour/marc21/obligatoire/marc21_framework_DEFAULT.sql @@ -849,7 +849,7 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ("245","6","Liaison","Liaison","0","0","","2","","","","0","-6","","","","","9999"), ("245","8","Numéro de liaison de zone et de séquence","Numéro de liaison de zone et de séquence","1","0","","2","","","","0","-6","","","","","9999"), ("245","a","Titre","Titre","0","1","biblio.title","2","","","","0","0","","'245b','245f','245g','245k','245n','245p','245s','245h','246i','246a','246b','246f','246g','246n','246p','246h','242a','242b','242n','242p','242h','505t'","","","9999"), -("245","b","Reste du titre","Reste du titre","0","0","bibliosubtitle.subtitle","2","","","","0","0","","","","","9999"), +("245","b","Reste du titre","Reste du titre","0","0","biblio.subtitle","2","","","","0","0","","","","","9999"), ("245","c","Mention de responsabilité, etc.","Mention de responsabilité, etc.","0","0","","2","","","","0","0","","","","","9999"), ("245","f","Dates extrêmes","Dates extrêmes","0","0","","2","","","","0","-6","","","","","9999"), ("245","g","Dates générales","Dates générales","0","0","","2","","","","0","-6","","","","","9999"), diff --git a/installer/data/mysql/fr-FR/marcflavour/marc21/Obligatoire/marc21_framework_DEFAULT.sql b/installer/data/mysql/fr-FR/marcflavour/marc21/Obligatoire/marc21_framework_DEFAULT.sql index 0e64938f5b..ecd2aac6c7 100644 --- a/installer/data/mysql/fr-FR/marcflavour/marc21/Obligatoire/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/fr-FR/marcflavour/marc21/Obligatoire/marc21_framework_DEFAULT.sql @@ -967,7 +967,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -975,8 +975,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/fr-FR/marcflavour/marc21/Optionnel/marc21_simple_bib_frameworks.sql b/installer/data/mysql/fr-FR/marcflavour/marc21/Optionnel/marc21_simple_bib_frameworks.sql index 294d4237ec..17518dc6bd 100644 --- a/installer/data/mysql/fr-FR/marcflavour/marc21/Optionnel/marc21_simple_bib_frameworks.sql +++ b/installer/data/mysql/fr-FR/marcflavour/marc21/Optionnel/marc21_simple_bib_frameworks.sql @@ -992,7 +992,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'BKS', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'BKS', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'BKS', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'BKS', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), @@ -1000,8 +1000,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, -1, 'BKS', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'BKS', '', '', NULL), @@ -4919,7 +4919,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'CF', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'CF', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'CF', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'CF', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), @@ -4927,8 +4927,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, 'CF', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'CF', '', '', NULL), @@ -8845,7 +8845,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'SR', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'SR', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'SR', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'SR', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), @@ -8853,8 +8853,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, 'SR', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'SR', '', '', NULL), @@ -12771,7 +12771,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'VR', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'VR', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'VR', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'VR', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), @@ -12779,8 +12779,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, 'VR', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'VR', '', '', NULL), @@ -16695,7 +16695,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'AR', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'AR', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'AR', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'AR', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), @@ -16703,8 +16703,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, 'AR', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'AR', '', '', NULL), @@ -20619,7 +20619,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'KT', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'KT', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'KT', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'KT', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), @@ -20627,8 +20627,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, 'KT', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'KT', '', '', NULL), @@ -24545,7 +24545,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'IR', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'IR', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'IR', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'IR', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), @@ -24553,8 +24553,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, -1, 'IR', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'IR', '', '', NULL), @@ -28466,7 +28466,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, 'SER', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, 'SER', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, 'SER', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, 'SER', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, 'SER', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, 'SER', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'SER', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, 'SER', '', '', NULL), diff --git a/installer/data/mysql/it-IT/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql b/installer/data/mysql/it-IT/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql index d22c1b7936..c7bc9d4ee0 100644 --- a/installer/data/mysql/it-IT/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/it-IT/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql @@ -1037,7 +1037,7 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', '6', 'Collegamento', 'Collegamento', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Numero di collegamento e di sequenza di campi', 'Numero di collegamento e di sequenza di campi', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Titolo', 'Titolo', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Complemento del titolo', 'Complemento del titolo', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Complemento del titolo', 'Complemento del titolo', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Formulazione di responsabilità, ecc.', 'Formulazione di responsabilità, ecc.', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section/part/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -1045,8 +1045,8 @@ INSERT IGNORE INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblib ('245', 'g', 'Date preponderanti', 'Date preponderanti', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Supporto', 'Supporto', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Forma', 'Forma', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Numero di parte/sezione dell\'opera', 'Numero di parte/sezione dell\'opera', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Nome di parte/sezione dell\'opera', 'Nome di parte/sezione dell\'opera', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Numero di parte/sezione dell\'opera', 'Numero di parte/sezione dell\'opera', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Nome di parte/sezione dell\'opera', 'Nome di parte/sezione dell\'opera', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Versione', 'Versione', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Istituzione a cui si applica il campo', 'Istituzione a cui si applica il campo', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Collegamento', 'Collegamento', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index 7b78a87b76..d18b0632de 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -132,6 +132,10 @@ CREATE TABLE `biblio` ( -- table that stores bibliographic information `frameworkcode` varchar(4) NOT NULL default '', -- foreign key from the biblio_framework table to identify which framework was used in cataloging this record `author` LONGTEXT, -- statement of responsibility from MARC record (100$a in MARC21) `title` LONGTEXT, -- title (without the subtitle) from the MARC record (245$a in MARC21) + `medium` LONGTEXT, -- medium from the MARC record (245$h in MARC21) + `subtitle` LONGTEXT, -- remainder of the title from the MARC record (245$b in MARC21) + `part_number` LONGTEXT, -- part number from the MARC record (245$n in MARC21) + `part_name` LONGTEXT, -- part name from the MARC record (245$p in MARC21) `unititle` LONGTEXT, -- uniform title (without the subtitle) from the MARC record (240$a in MARC21) `notes` LONGTEXT, -- values from the general notes field in the MARC record (500$a in MARC21) split by bar (|) `serial` tinyint(1) default NULL, -- Boolean indicating whether biblio is for a serial @@ -469,6 +473,10 @@ CREATE TABLE `deletedbiblio` ( -- stores information about bibliographic records `frameworkcode` varchar(4) NOT NULL default '', -- foriegn key from the biblio_framework table to identify which framework was used in cataloging this record `author` LONGTEXT, -- statement of responsibility from MARC record (100$a in MARC21) `title` LONGTEXT, -- title (without the subtitle) from the MARC record (245$a in MARC21) + `medium` LONGTEXT, -- medium from the MARC record (245$h in MARC21) + `subtitle` LONGTEXT, -- remainder of the title from the MARC record (245$b in MARC21) + `part_number` LONGTEXT, -- part number from the MARC record (245$n in MARC21) + `part_name` LONGTEXT, -- part name from the MARC record (245$p in MARC21) `unititle` LONGTEXT, -- uniform title (without the subtitle) from the MARC record (240$a in MARC21) `notes` LONGTEXT, -- values from the general notes field in the MARC record (500$a in MARC21) split by bar (|) `serial` tinyint(1) default NULL, -- Boolean indicating whether biblio is for a serial diff --git a/installer/data/mysql/nb-NO/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql b/installer/data/mysql/nb-NO/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql index fc3dec16a0..656f021362 100644 --- a/installer/data/mysql/nb-NO/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/nb-NO/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql @@ -967,7 +967,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -975,8 +975,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/nb-NO/marcflavour/normarc/Obligatorisk/normarc.sql b/installer/data/mysql/nb-NO/marcflavour/normarc/Obligatorisk/normarc.sql index 7956a3fa0c..ef645c7a51 100644 --- a/installer/data/mysql/nb-NO/marcflavour/normarc/Obligatorisk/normarc.sql +++ b/installer/data/mysql/nb-NO/marcflavour/normarc/Obligatorisk/normarc.sql @@ -263,11 +263,11 @@ INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,r INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('240','s','Versjon','Versjon','0','0','0','2','','','','0','-1','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('240','w','Sorteringsdelfelt for delfelt $a','Sorteringsdelfelt for delfelt $a','0','0','0','2','','','','0','-1','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','a','Tittel','Tittel','0','0','biblio.title','2','','','','0','0','','','',NULL,'9999'); -INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','b','Annen tittelinformasjon','Annen tittelinformasjon','0','0','bibliosubtitle.subtitle','2','','','','0','0','','','',NULL,'9999'); +INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','b','Annen tittelinformasjon','Annen tittelinformasjon','0','0','biblio.subtitle','2','','','','0','0','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','c','Ansvarsangivelse','Ansvarsangivelse','0','0','0','2','','','','0','0','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','h','Generell materialbetegnelse','Generell materialbetegnelse','0','0','0','2','','','','0','0','','','',NULL,'9999'); -INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','n','Nummer for del av verk','Nummer for del av verk','0','0','0','2','','','','0','0','','','',NULL,'9999'); -INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','p','Tittel for del av verk','Tittel for del av verk','0','0','0','2','','','','0','0','','','',NULL,'9999'); +INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','n','Nummer for del av verk','Nummer for del av verk','0','0','biblio.part_number','2','','','','0','0','','','',NULL,'9999'); +INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','p','Tittel for del av verk','Tittel for del av verk','0','0','biblio.part_name','2','','','','0','0','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('245','w','Sorteringsdelfelt for delfelt $a','Sorteringsdelfelt for delfelt $a','0','0','0','2','','','','0','0','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('246','a','Parallelltittel','Parallelltittel','0','0','0','2','','','','0','-1','','','',NULL,'9999'); INSERT INTO marc_subfield_structure (tagfield,tagsubfield,liblibrarian,libopac,repeatable,mandatory,kohafield,tab,authorised_value,authtypecode,value_builder,isurl,hidden,frameworkcode,seealso,link,defaultvalue,maxlength) VALUES ('246','b','Annen tittelinformasjon','Annen tittelinformasjon','0','0','0','2','','','','0','-1','','','',NULL,'9999'); diff --git a/installer/data/mysql/pl-PL/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql b/installer/data/mysql/pl-PL/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql index 3fa7ef4728..ab6ec6551c 100644 --- a/installer/data/mysql/pl-PL/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql +++ b/installer/data/mysql/pl-PL/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql @@ -966,7 +966,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'a', 'Title', 'Title', 0, 1, 'biblio.title', 2, '', '', '', NULL, 0, '', '''245b'',''245f'',''245g'',''245k'',''245n'',''245p'',''245s'',''245h'',''246i'',''246a'',''246b'',''246f'',''246g'',''246n'',''246p'',''246h'',''242a'',''242b'',''242n'',''242p'',''242h'',''505t''', '', NULL), - ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'bibliosubtitle.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), + ('245', 'b', 'Remainder of title', 'Remainder of title', 0, 0, 'biblio.subtitle', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'c', 'Statement of responsibility, etc', 'Statement of responsibility, etc', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'd', 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'e', 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), @@ -974,8 +974,8 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` ('245', 'g', 'Bulk dates', 'Bulk dates', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 'h', 'Medium', 'Medium', 0, 0, '', 2, '', '', '', NULL, 0, '', '', '', NULL), ('245', 'k', 'Form', 'Form', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), - ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'n', 'Number of part/section of a work', 'Number of part/section of a work', 1, 0, 'biblio.part_number', 2, '', '', '', NULL, -6, '', '', '', NULL), + ('245', 'p', 'Name of part/section of a work', 'Name of part/section of a work', 1, 0, 'biblio.part_name', 2, '', '', '', NULL, -6, '', '', '', NULL), ('245', 's', 'Version', 'Version', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '5', 'Institution to which field applies', 'Institution to which field applies', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), ('246', '6', 'Linkage', 'Linkage', 0, 0, '', 2, '', '', '', NULL, -6, '', '', '', NULL), diff --git a/installer/data/mysql/ru-RU/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql b/installer/data/mysql/ru-RU/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql index 183378d7d0..d0f4066596 100644 --- a/installer/data/mysql/ru-RU/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql +++ b/installer/data/mysql/ru-RU/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql @@ -792,7 +792,7 @@ INSERT INTO marc_subfield_structure (frameworkcode, authtypecode, tagfield, tag ('', '', '245', '6', 0, 0, 'Элемент связи', '', 2, -6, '', '', '', NULL, '', '', NULL), ('', '', '245', '8', 0, 1, 'Связь поля и ее порядковый номер', '', 2, -6, '', '', '', NULL, '', '', NULL), ('', '', '245', 'a', 0, 0, 'Заглавие', '', 2, 0, 'biblio.title', '', '', NULL, '\'245b\',\'245f\',\'245g\',\'245k\',\'245n\',\'245p\',\'245s\',\'245h\',\'246i\',\'246a\',\'246b\',\'246f\',\'246g\',\'246n\',\'246p\',\'246h\',\'242a\',\'242b\',\'242n\',\'242p\',\'242h\',\'505t\'', '', NULL), - ('', '', '245', 'b', 0, 0, 'Продолж. заглавия', '', 2, 0, 'bibliosubtitle.subtitle', '', '', NULL, '', '', NULL), + ('', '', '245', 'b', 0, 0, 'Продолж. заглавия', '', 2, 0, 'biblio.subtitle', '', '', NULL, '', '', NULL), ('', '', '245', 'c', 0, 0, 'Ответственность', '', 2, 0, '', '', '', NULL, '', '', NULL), ('', '', '245', 'd', 0, 0, 'Designation of section/part/series (SE) (устаревшее)', 'Designation of section section/part/series: (SE) (устаревшее)', 2, -6, '', '', '', NULL, '', '', NULL), ('', '', '245', 'e', 0, 0, 'Name of part/section/series (SE) (устаревшее)', 'Name of part/section/series (SE) (устаревшее)', 2, -6, '', '', '', NULL, '', '', NULL), @@ -800,8 +800,8 @@ INSERT INTO marc_subfield_structure (frameworkcode, authtypecode, tagfield, tag ('', '', '245', 'g', 0, 0, 'Даты создания осн. части произв.', '', 2, -6, '', '', '', NULL, '', '', NULL), ('', '', '245', 'h', 0, 0, 'Физический носитель', '', 2, 0, '', '', '', NULL, '', '', NULL), ('', '', '245', 'k', 0, 1, 'Форма, вид, жанр', '', 2, -6, '', '', '', NULL, '', '', NULL), - ('', '', '245', 'n', 0, 1, 'Номер части/раздела', '', 2, -6, '', '', '', NULL, '', '', NULL), - ('', '', '245', 'p', 0, 1, 'Название части/раздела', '', 2, -6, '', '', '', NULL, '', '', NULL), + ('', '', '245', 'n', 0, 1, 'Номер части/раздела', '', 2, -6, 'biblio.part_number', '', '', NULL, '', '', NULL), + ('', '', '245', 'p', 0, 1, 'Название части/раздела', '', 2, -6, 'biblio.part_name', '', '', NULL, '', '', NULL), ('', '', '245', 's', 0, 0, 'Версия', '', 2, -6, '', '', '', NULL, '', '', NULL); INSERT INTO marc_tag_structure (frameworkcode, tagfield, mandatory, repeatable, liblibrarian, libopac, authorised_value) VALUES diff --git a/installer/data/mysql/uk-UA/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql b/installer/data/mysql/uk-UA/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql index 74eb9dfd28..fe7d602067 100644 --- a/installer/data/mysql/uk-UA/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql +++ b/installer/data/mysql/uk-UA/marcflavour/marc21/mandatory/marc21_bibliographic_DEFAULT_general.sql @@ -833,7 +833,7 @@ INSERT INTO marc_subfield_structure (frameworkcode, authtypecode, tagfield, tag ('', '', '245', '6', 0, 0, 'Елемент зв’язку', '', 2, -6, '', '', '', 0, NULL, '', ''), ('', '', '245', '8', 0, 1, 'Зв’язок поля та його порядковий номер', '', 2, -6, '', '', '', 0, NULL, '', ''), ('', '', '245', 'a', 0, 0, 'Назва', '', 2, 0, 'biblio.title', '', '', 0, NULL, '', ''), - ('', '', '245', 'b', 0, 0, 'Продовж. назви', '', 2, 0, '', '', '', 0, NULL, '', ''), + ('', '', '245', 'b', 0, 0, 'Продовж. назви', '', 2, 0, 'biblio.subtitle', '', '', 0, NULL, '', ''), ('', '', '245', 'c', 0, 0, 'Відповідальність', '', 2, 0, '', '', '', 0, NULL, '', ''), ('', '', '245', 'd', 0, 0, 'Designation of section/part/series (SE) [OBSOLETE]', 'Designation of section section/part/series: (SE) [OBSOLETE]', 2, -6, '', '', '', 0, NULL, '', ''), ('', '', '245', 'e', 0, 0, 'Name of part/section/series (SE) [OBSOLETE]', 'Name of part/section/series (SE) [OBSOLETE]', 2, -6, '', '', '', 0, NULL, '', ''), @@ -841,8 +841,8 @@ INSERT INTO marc_subfield_structure (frameworkcode, authtypecode, tagfield, tag ('', '', '245', 'g', 0, 0, 'Дати створення осн. частини твору', '', 2, -6, '', '', '', 0, NULL, '', ''), ('', '', '245', 'h', 0, 0, 'Фізичний носій', '', 2, 0, '', '', '', 0, NULL, '', ''), ('', '', '245', 'k', 0, 1, 'Форма, вид, жанр', '', 2, -6, '', '', '', 0, NULL, '', ''), - ('', '', '245', 'n', 0, 1, 'Номер частини/розділу', '', 2, -6, '', '', '', 0, NULL, '', ''), - ('', '', '245', 'p', 0, 1, 'Назва частини/розділу', '', 2, -6, '', '', '', 0, NULL, '', ''), + ('', '', '245', 'n', 0, 1, 'Номер частини/розділу', '', 2, -6, 'biblio.part_number', '', '', 0, NULL, '', ''), + ('', '', '245', 'p', 0, 1, 'Назва частини/розділу', '', 2, -6, 'biblio.part_name', '', '', 0, NULL, '', ''), ('', '', '245', 's', 0, 0, 'Версія', '', 2, -6, '', '', '', 0, NULL, '', ''); INSERT INTO marc_tag_structure (frameworkcode, tagfield, mandatory, repeatable, liblibrarian, libopac, authorised_value) VALUES diff --git a/t/db_dependent/Biblio.t b/t/db_dependent/Biblio.t index dd96e546ff..42a4356848 100755 --- a/t/db_dependent/Biblio.t +++ b/t/db_dependent/Biblio.t @@ -130,6 +130,10 @@ $biblio_module->mock( my ($self) = shift; my ( $title_field, $title_subfield ) = get_title_field(); + my ( $subtitle_field, $subtitle_subfield ) = get_subtitle_field(); + my ( $medium_field, $medium_subfield ) = get_medium_field(); + my ( $part_number_field, $part_number_subfield ) = get_part_number_field(); + my ( $part_name_field, $part_name_subfield ) = get_part_name_field(); my ( $isbn_field, $isbn_subfield ) = get_isbn_field(); my ( $issn_field, $issn_subfield ) = get_issn_field(); my ( $biblionumber_field, $biblionumber_subfield ) = ( '999', 'c' ); @@ -138,6 +142,10 @@ $biblio_module->mock( return { 'biblio.title' => [ { tagfield => $title_field, tagsubfield => $title_subfield } ], + 'biblio.subtitle' => [ { tagfield => $subtitle_field, tagsubfield => $subtitle_subfield } ], + 'biblio.medium' => [ { tagfield => $medium_field, tagsubfield => $medium_subfield } ], + 'biblio.part_number' => [ { tagfield => $part_number_field, tagsubfield => $part_number_subfield } ], + 'biblio.part_name' => [ { tagfield => $part_name_field, tagsubfield => $part_name_subfield } ], 'biblio.biblionumber' => [ { tagfield => $biblionumber_field, tagsubfield => $biblionumber_subfield } ], 'biblioitems.isbn' => [ { tagfield => $isbn_field, tagsubfield => $isbn_subfield } ], 'biblioitems.issn' => [ { tagfield => $issn_field, tagsubfield => $issn_subfield } ], @@ -168,6 +176,11 @@ sub run_tests { my $isbn = '0590353403'; my $title = 'Foundation'; + my $subtitle1 = 'Research'; + my $subtitle2 = 'Conclusions'; + my $medium = 'Medium'; + my $part_number = '123'; + my $part_name = 'First years'; # Generate a record with just the ISBN my $marc_record = MARC::Record->new; @@ -197,6 +210,23 @@ sub run_tests { my ( $title_field, $title_subfield ) = get_title_field(); is( $marc->subfield( $title_field, $title_subfield ), $title, ); + # Add other fields + $marc_record->append_fields( create_field( $subtitle1, $marcflavour, get_subtitle_field() ) ); + $marc_record->append_fields( create_field( $subtitle2, $marcflavour, get_subtitle_field() ) ); + $marc_record->append_fields( create_field( $medium, $marcflavour, get_medium_field() ) ); + $marc_record->append_fields( create_field( $part_number, $marcflavour, get_part_number_field() ) ); + $marc_record->append_fields( create_field( $part_name, $marcflavour, get_part_name_field() ) ); + + ModBiblio( $marc_record, $biblionumber ,'' ); + $data = GetBiblioData( $biblionumber ); + is( $data->{ title }, $title, '(ModBiblio) still there after adding other fields.' ); + is( $data->{ isbn }, $isbn, '(ModBiblio) ISBN is still there after adding other fields.' ); + + is( $data->{ subtitle }, "$subtitle1 | $subtitle2", '(ModBiblio) subtitles correctly added and returned in GetBiblioData.' ); + is( $data->{ medium }, $medium, '(ModBiblio) medium correctly added and returned in GetBiblioData.' ); + is( $data->{ part_number }, $part_number, '(ModBiblio) part_number correctly added and returned in GetBiblioData.' ); + is( $data->{ part_name }, $part_name, '(ModBiblio) part_name correctly added and returned in GetBiblioData.' ); + my $biblioitem = Koha::Biblioitems->find( $biblioitemnumber ); is( $biblioitem->_result->biblio->title, $title, # Should be $biblioitem->biblio instead, but not needed elsewhere for now 'Do not know if this makes sense - compare result of previous two GetBiblioData tests.'); @@ -352,14 +382,15 @@ sub run_tests { # Automatic authority creation t::lib::Mocks::mock_preference('BiblioAddsAuthorities', 1); t::lib::Mocks::mock_preference('AutoCreateAuthorities', 1); - my $authorities_mod = Test::MockModule->new( 'C4::AuthoritiesMarc' ); + my $authorities_mod = Test::MockModule->new( 'C4::Heading' ); $authorities_mod->mock( - 'SearchAuthorities', + 'authorities', sub { my @results; - return \@results, 0; + return \@results; } ); + $success = 0; $field = create_author_field('Author Name'); eval { @@ -403,6 +434,26 @@ sub get_title_field { return ( $marc_flavour eq 'UNIMARC' ) ? ( '200', 'a' ) : ( '245', 'a' ); } +sub get_medium_field { + my $marc_flavour = C4::Context->preference('marcflavour'); + return ( $marc_flavour eq 'UNIMARC' ) ? ( '200', 'b' ) : ( '245', 'h' ); +} + +sub get_subtitle_field { + my $marc_flavour = C4::Context->preference('marcflavour'); + return ( $marc_flavour eq 'UNIMARC' ) ? ( '200', 'e' ) : ( '245', 'b' ); +} + +sub get_part_number_field { + my $marc_flavour = C4::Context->preference('marcflavour'); + return ( $marc_flavour eq 'UNIMARC' ) ? ( '200', 'h' ) : ( '245', 'n' ); +} + +sub get_part_name_field { + my $marc_flavour = C4::Context->preference('marcflavour'); + return ( $marc_flavour eq 'UNIMARC' ) ? ( '200', 'i' ) : ( '245', 'p' ); +} + sub get_isbn_field { my $marc_flavour = C4::Context->preference('marcflavour'); return ( $marc_flavour eq 'UNIMARC' ) ? ( '010', 'a' ) : ( '020', 'a' ); @@ -437,6 +488,12 @@ sub create_title_field { return $field; } +sub create_field { + my ( $content, $marcflavour, $field, $subfield ) = @_; + + return MARC::Field->new( $field, '', '', $subfield => $content ); +} + sub create_isbn_field { my ( $isbn, $marcflavour ) = @_; @@ -473,14 +530,14 @@ sub create_author_field { } subtest 'MARC21' => sub { - plan tests => 42; + plan tests => 48; run_tests('MARC21'); $schema->storage->txn_rollback; $schema->storage->txn_begin; }; subtest 'UNIMARC' => sub { - plan tests => 42; + plan tests => 48; # Mock the auth type data for UNIMARC $dbh->do("UPDATE auth_types SET auth_tag_to_report = '106' WHERE auth_tag_to_report = '100'") or die $dbh->errstr; @@ -491,7 +548,7 @@ subtest 'UNIMARC' => sub { }; subtest 'NORMARC' => sub { - plan tests => 42; + plan tests => 48; run_tests('NORMARC'); $schema->storage->txn_rollback; $schema->storage->txn_begin; -- 2.17.1