X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/e056a4197167456cf16b815525f4c62a5321c550..4f19857efd5a26253699b24a305176fda21b010a:/SL/CT.pm diff --git a/SL/CT.pm b/SL/CT.pm index b1c21ab22..7e81d66c4 100644 --- a/SL/CT.pm +++ b/SL/CT.pm @@ -761,17 +761,17 @@ if ($sortorder ne 'id') { $where .= qq| AND ($cvar_where)|; push @values, @cvar_values; } - # Um nach Straße in der Berichtsmaske zu suchen ... jb 13.11.2008 - if ($form->{addr_street}) { - $where .= qq| AND (street ILIKE ?)|; - push @values, ('%' . $form->{addr_street} . '%'); - } - - # Um nach PLZ in der Berichtsmaske zu suchen ... jb 13.11.2008 - if ($form->{addr_zipcode}) { - $where .= qq| AND (zipcode ILIKE ?)|; - push @values, ($form->{addr_zipcode} . '%'); - } + + if ($form->{addr_street}) { + $where .= qq| AND (street ILIKE ?)|; + push @values, '%' . $form->{addr_street} . '%'; + } + + if ($form->{addr_zipcode}) { + $where .= qq| AND (zipcode ILIKE ?)|; + push @values, $form->{addr_zipcode} . '%'; + } + my $query = qq|SELECT ct.*, b.description AS business | . qq|FROM $cv ct | .