From d7b6d43a2e08f5c1ed6d2741505fd152373892ea Mon Sep 17 00:00:00 2001 From: Katrin Fischer Date: Sun, 8 Aug 2010 21:19:41 +0200 Subject: [PATCH] Bug 5092: No results when searching by LC Call Number: in Z39.50 Server Signed-off-by: Galen Charlton --- acqui/z3950_search.pl | 6 ++++++ cataloguing/z3950_search.pl | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/acqui/z3950_search.pl b/acqui/z3950_search.pl index 444c893dc4..0215873c1e 100755 --- a/acqui/z3950_search.pl +++ b/acqui/z3950_search.pl @@ -54,6 +54,7 @@ my $author = $input->param('author'); my $isbn = $input->param('isbn'); my $issn = $input->param('issn'); my $lccn = $input->param('lccn'); +my $lccall = $input->param('lccall'); my $subject= $input->param('subject'); my $dewey = $input->param('dewey'); my $op = $input->param('op'); @@ -114,6 +115,7 @@ if ( $op ne "do_search" ) { isbn => $isbn, issn => $issn, lccn => $lccn, + lccall => $lccall, title => $title, author => $author, serverloop => $serverloop, @@ -158,6 +160,10 @@ else { $query .= " \@attr 1=9 $lccn "; $nterms++; } + if ($lccall) { + $query .= " \@attr 1=16 \@attr 2=3 \@attr 3=1 \@attr 4=1 \@attr 5=1 \@attr 6=1 \"$lccall\" "; + $nterms++; + } for my $i (1..$nterms-1) { $query = "\@and " . $query; } diff --git a/cataloguing/z3950_search.pl b/cataloguing/z3950_search.pl index cf9e7b2ff4..9b6c8f1d19 100755 --- a/cataloguing/z3950_search.pl +++ b/cataloguing/z3950_search.pl @@ -41,6 +41,7 @@ my $author = $input->param('author'); my $isbn = $input->param('isbn'); my $issn = $input->param('issn'); my $lccn = $input->param('lccn'); +my $lccall = $input->param('lccall'); my $subject = $input->param('subject'); my $dewey = $input->param('dewey'); my $controlnumber = $input->param('controlnumber'); @@ -88,6 +89,7 @@ if ( $op ne "do_search" ) { isbn => $isbn, issn => $issn, lccn => $lccn, + lccall => $lccall, title => $title, author => $author, controlnumber=> $controlnumber, @@ -136,6 +138,10 @@ else { $query .= " \@attr 1=9 $lccn "; $nterms++; } + if ($lccall) { + $query .= " \@attr 1=16 \@attr 2=3 \@attr 3=1 \@attr 4=1 \@attr 5=1 \@attr 6=1 \"$lccall\" "; + $nterms++; + } if ($controlnumber) { $query .= " \@attr 1=12 \"$controlnumber\" "; $nterms++; -- 2.39.5