Only add % to value if % is not present.
This commit is contained in:
parent
4b71bc75ea
commit
e232c22b3d
|
@ -239,7 +239,7 @@ sub Sql {
|
|||
if ( $term->{op} eq 'LIKE'
|
||||
|| $term->{op} eq 'NOT LIKE'
|
||||
) {
|
||||
$temp_value = '%'.$temp_value.'%';
|
||||
$temp_value = '%'.$temp_value.'%' if $temp_value !~ /%/;
|
||||
}
|
||||
$value = "'$temp_value'";
|
||||
} elsif ( $term->{attr} eq 'DateTime' or $term->{attr} eq 'StartDateTime' or $term->{attr} eq 'EndDateTime' ) {
|
||||
|
|
Loading…
Reference in New Issue