From 63a3558b3aadd11eba5983314a735ef5dc331374 Mon Sep 17 00:00:00 2001 From: Josh Stompro Date: Thu, 28 Feb 2019 08:39:54 -0600 Subject: [PATCH] LP#1800871 - MARC21slim2MADS 2.15 update This update fixes an error when trying to process a 755 tag in and authority record that has a source set. See the discussion on the listserv at: https://georgialibraries.markmail.org/thread/rmwcxkwjzv2qczmu To test, try to import the sample authority record provided by Linda Jansova (https://markmail.org/thread/2ay3j4wg7fecymhz) in evergreen, and see the log files for the import errors. It is also possible to test from the command line. In /openils/var/xsl, copy the example autority marc xml file to that directory, name it americ.xml, then run the command xsltproc ./MARC21slim2MADS.xsl ./americ.xml This will error out. After patch has been applied, try importing the sample authority record and see that it imports successfully. Signed-off-by: Josh Stompro Signed-off-by: Jane Sandberg Signed-off-by: Jason Boyer --- Open-ILS/src/sql/Pg/955.data.MADS21-xsl.sql | 3 +- .../src/sql/Pg/upgrade/XXXX.data.MADS21-xsl.sql | 1631 ++++++++++++++++++++ Open-ILS/xsl/MARC21slim2MADS.xsl | 5 +- 3 files changed, 1636 insertions(+), 3 deletions(-) create mode 100644 Open-ILS/src/sql/Pg/upgrade/XXXX.data.MADS21-xsl.sql diff --git a/Open-ILS/src/sql/Pg/955.data.MADS21-xsl.sql b/Open-ILS/src/sql/Pg/955.data.MADS21-xsl.sql index 94fb59a32b..76498ebf10 100644 --- a/Open-ILS/src/sql/Pg/955.data.MADS21-xsl.sql +++ b/Open-ILS/src/sql/Pg/955.data.MADS21-xsl.sql @@ -181,6 +181,7 @@ UPDATE config.xml_transform SET xslt=$XSLT$ tmee 01/31/2014 2.12 added $2 authority for tmee 09/18/2012 @@ -1254,8 +1255,8 @@ UPDATE config.xml_transform SET xslt=$XSLT$ - + diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.MADS21-xsl.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.MADS21-xsl.sql new file mode 100644 index 0000000000..e1ed27d373 --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.MADS21-xsl.sql @@ -0,0 +1,1631 @@ +BEGIN; + +-- SELECT evergreen.upgrade_deps_block_check('xxxx', :eg_version); + +INSERT INTO config.xml_transform (name,namespace_uri,prefix,xslt) VALUES ('mads21','http://www.loc.gov/mads/v2','mads21',$XSLT$ + + + + + + !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ + + + + ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ + + + + !'()*-.0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz~ + + + 0123456789ABCDEF + + + + + + + + + + + + + + + + + + + + + + + + + + + abcdefghijklmnopqrstuvwxyz + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + .:,;/ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + .:,;/] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Warning: string contains a character + that is out of range! Substituting "?". + 63 + + + + + + + + + + + + + + + + + + + + + + + + + + + + naf + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + direct + + + + + indirect + + + + + not applicable + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Converted from MARCXML to MADS version 2.0 (Revision 2.13) + + + + + + + + + + + earlier rules + + + + + aacr1 + + + + + aacr2 + + + + + aacr2 compatible + + + + + other rules + + + + + + + + + + + + + + + + + + + + + + + n + n + fghkdlmor + + + + + p + p + fghkdlmor + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + cdn + + + + + + + + + + + aq + + + + + + + + + + + + acdenq + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + bc + + + + + + + + + + + + + + + + + + + + + + + yes + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + a + + - + + st + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + abcdxyz + - + + + + + + + + abcdxyz + - + + + + + + + + abcdxyz + - + + + + + + + + + + abcdxyz + - + + + + + + + abcdxyz5 + - + + + + + + + + + + abcdxyz5 + - + + + + + + + + + + abcdxyz5 + - + + + + + + + + + + abcdxyz5 + - + + + + + + + + + + abcdxyz5 + - + + + + + + + + + + abcdxyz5 + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ab + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + nonpublic + + + source + + + notFound + + + history + + + subject example + + + deleted heading information + + + application history + + + + + + + + + + + ab + + + + + ai + + + + + + + + + + + + + + + z3 + + + + + + + + + + + + earlier + + + later + + + parentOrg + + + broader + + + narrower + + + other + + + other + + + + other + + + + equivalent + + + + + + + + + + + + acronym + + + other + + + other + + + + + other + + + + + + + + + + + + naf + + + + + lcsh + + + + + lacnaf + + + + + lcsh + + + + cash + + + naf + + + lcsh + + + + lacnaf + + + + + cash + + + + + lcshcl + + + + + nlmnaf + + + + + nalnaf + + + + + aat + + + + sears + + + rvm + + + + + + + + + naf + + + + + lcsh + + + + + lacnaf + + + + + lcsh + + + + + lcsh + + + + + mesh + + + + + nal + + + + + cash + + + + + naf + + + + lcsh + + + lacnaf + + + cash + + + lcsh + + + naf + + + lacnaf + + + lcsh + + + cash + + + lcshcl + + + nlmnaf + + + nalnaf + + + rvm + + + + + + + + lacnaf + + + naf + + + lcsh + + + mesh + + + nal + + + cash + + + + +$XSLT$); + +COMMIT; diff --git a/Open-ILS/xsl/MARC21slim2MADS.xsl b/Open-ILS/xsl/MARC21slim2MADS.xsl index 645406ac1d..48111c65bb 100644 --- a/Open-ILS/xsl/MARC21slim2MADS.xsl +++ b/Open-ILS/xsl/MARC21slim2MADS.xsl @@ -8,7 +8,8 @@