[open-ils-commits] r9361 - branches/rel_1_2/Open-ILS/src/sql/Pg

svn at svn.open-ils.org svn at svn.open-ils.org
Tue Apr 15 10:49:37 EDT 2008


Author: miker
Date: 2008-04-15 10:11:30 -0400 (Tue, 15 Apr 2008)
New Revision: 9361

Modified:
   branches/rel_1_2/Open-ILS/src/sql/Pg/020.schema.functions.sql
Log:
updating dewey extractor

Modified: branches/rel_1_2/Open-ILS/src/sql/Pg/020.schema.functions.sql
===================================================================
--- branches/rel_1_2/Open-ILS/src/sql/Pg/020.schema.functions.sql	2008-04-15 12:18:51 UTC (rev 9360)
+++ branches/rel_1_2/Open-ILS/src/sql/Pg/020.schema.functions.sql	2008-04-15 14:11:30 UTC (rev 9361)
@@ -21,12 +21,12 @@
 	$txt =~ s/^\s+//o;
 	$txt =~ s/[\[\]\{\}\(\)`'"#<>\*\?\-\+\$\\]+//o;
 	$txt =~ s/\s+$//o;
-	if (/(\d{3}(?:\.\d+)?)/o) {
+	if ($txt =~ /(\d{3}(?:\.\d+)?)/o) {
 		return $1;
 	} else {
 		return (split /\s+/, $txt)[0];
 	}
-$$ LANGUAGE 'plperl' STRICT IMMUTABLE;
+$$ LANGUAGE 'plperlu' STRICT IMMUTABLE;
 
 CREATE OR REPLACE FUNCTION public.call_number_dewey( TEXT, INT ) RETURNS TEXT AS $$
 	SELECT SUBSTRING(call_number_dewey($1) FROM 1 FOR $2);



More information about the open-ils-commits mailing list