View | Details | Raw Unified | Return to bug 8350
Collapse All | Expand All

(-)a/C4/Breeding.pm (-5 / +4 lines)
Lines 179-194 sub BreedingSearch { Link Here
179
        $query .= "z3950random = ?";
179
        $query .= "z3950random = ?";
180
        @bind=($z3950random);
180
        @bind=($z3950random);
181
    } else {
181
    } else {
182
        $search =~ s/(\s+)/\%/g;
183
        @bind=();
182
        @bind=();
184
    if ($search) {
183
        if (defined($search) && length($search)>0) {
184
            $search =~ s/(\s+)/\%/g;
185
            $query .= "title like ? OR author like ?";
185
            $query .= "title like ? OR author like ?";
186
            push(@bind,"%$search%", "%$search%");
186
            push(@bind,"%$search%", "%$search%");
187
        }
187
        }
188
        if ($search && $isbn) {
188
        if ($#bind!=-1 && defined($isbn) && length($isbn)>0) {
189
            $query .= " and ";
189
            $query .= " and ";
190
        }
190
        }
191
        if ($isbn) {
191
        if (defined($isbn) && length($isbn)>0) {
192
            $query .= "isbn like ?";
192
            $query .= "isbn like ?";
193
            push(@bind,"$isbn%");
193
            push(@bind,"$isbn%");
194
        }
194
        }
195
- 

Return to bug 8350