[Koha-cvs] CVS: koha/C4 Biblio.pm,1.58,1.59

Paul POULAIN tipaul at users.sourceforge.net
Thu Sep 4 12:17:09 CEST 2003


Update of /cvsroot/koha/koha/C4
In directory sc8-pr-cvs1:/tmp/cvs-serv32552/C4

Modified Files:
	Biblio.pm 
Log Message:
fix for 583 (values in marc_word table should have quotation marks, etc, stripped)

Index: Biblio.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Biblio.pm,v
retrieving revision 1.58
retrieving revision 1.59
diff -C2 -r1.58 -r1.59
*** Biblio.pm	6 Aug 2003 12:54:52 -0000	1.58
--- Biblio.pm	4 Sep 2003 10:17:07 -0000	1.59
***************
*** 2,5 ****
--- 2,8 ----
  # $Id$
  # $Log$
+ # Revision 1.59  2003/09/04 10:17:07  tipaul
+ # fix for 583 (values in marc_word table should have quotation marks, etc, stripped)
+ #
  # Revision 1.58  2003/08/06 12:54:52  tipaul
  # fix for publicationyear : extracting numeric value from MARC string, like for copyrightdate.
***************
*** 642,646 ****
  	foreach my $subfieldvalue (@subfieldvalues) {
  		if (length($subfieldvalue)>255) {
! 		#	$dbh->do("lock tables marc_blob_subfield WRITE, marc_subfield_table WRITE");
  			my $sth=$dbh->prepare("insert into marc_blob_subfield (subfieldvalue) values (?)");
  			$sth->execute($subfieldvalue);
--- 645,649 ----
  	foreach my $subfieldvalue (@subfieldvalues) {
  		if (length($subfieldvalue)>255) {
! 			$dbh->do("lock tables marc_blob_subfield WRITE, marc_subfield_table WRITE");
  			my $sth=$dbh->prepare("insert into marc_blob_subfield (subfieldvalue) values (?)");
  			$sth->execute($subfieldvalue);
***************
*** 653,657 ****
  				warn "ERROR ==> insert into marc_subfield_table (bibid,tag,tagorder,tag_indicator,subfieldcode,subfieldorder,subfieldvalue) values ($bibid,$tagid,$tagorder,$tag_indicator,$subfieldcode,$subfieldorder,$subfieldvalue)\n";
  			}
! 	#	$dbh->do("unlock tables");
  		} else {
  			my $sth=$dbh->prepare("insert into marc_subfield_table (bibid,tag,tagorder,tag_indicator,subfieldcode,subfieldorder,subfieldvalue) values (?,?,?,?,?,?,?)");
--- 656,660 ----
  				warn "ERROR ==> insert into marc_subfield_table (bibid,tag,tagorder,tag_indicator,subfieldcode,subfieldorder,subfieldvalue) values ($bibid,$tagid,$tagorder,$tag_indicator,$subfieldcode,$subfieldorder,$subfieldvalue)\n";
  			}
! 		$dbh->do("unlock tables");
  		} else {
  			my $sth=$dbh->prepare("insert into marc_subfield_table (bibid,tag,tagorder,tag_indicator,subfieldcode,subfieldorder,subfieldvalue) values (?,?,?,?,?,?,?)");
***************
*** 1162,1166 ****
  # removes stopwords
      my ($dbh,$bibid,$tag,$tagorder,$subfieldid,$subfieldorder,$sentence) =@_;
!     $sentence =~ s/(\.|\?|\:|\!|\'|,|\-)/ /g;
      my @words = split / /,$sentence;
      my $stopwords= C4::Context->stopwords;
--- 1165,1169 ----
  # removes stopwords
      my ($dbh,$bibid,$tag,$tagorder,$subfieldid,$subfieldorder,$sentence) =@_;
!     $sentence =~ s/(\.|\?|\:|\!|\'|,|\-|\"|\(|\)|\[|\]|\{|\})/ /g;
      my @words = split / /,$sentence;
      my $stopwords= C4::Context->stopwords;





More information about the Koha-cvs mailing list