treat full birth/death dates specially, as tsearch2 is inconsistent between 8.1 and 8.2
[Evergreen.git] / Open-ILS / src / perlmods / OpenILS / Application / Ingest.pm
index 39285ca..61694be 100644 (file)
@@ -695,6 +695,9 @@ sub xpath_to_string {
                        $string .= $value->textContent . " ";
                }
        }
+
+    $string =~ s/(\d{4})-(\d{4})/$1 $2/sgo;
+
        return NFD($string);
 }
 
@@ -900,6 +903,7 @@ sub _marcxml_to_full_rows {
                        $val =~ s/\pM+//sgo;
                        $val =~ s/\pC+//sgo;
                        $val =~ s/\W+$//sgo;
+            $val =~ s/(\d{4})-(\d{4})/$1 $2/sgo;
                        $ns->value( lc($val) );
 
                        push @ns_list, $ns;