Revision 780
- Date:
- 2019/08/18 22:19:52
- Files:
Legend:
- Added
- Removed
- Modified
-
utf8/core/lib/SQL/Common.pm
177 177 $mode = $negation ? 'IS NOT' : 'IS'; 178 178 return "$field $mode NULL", []; 179 179 } elsif (ref($value) eq 'ARRAY' and @$value) { 180 my $values_string = '?, 'x(scalar (@$value)-1).'?'; 181 return " ($field $mode ($values_string)) ", $value; 182 } elsif (ref($value) eq 'ARRAY') { 183 # skip empty array 184 return ($negation ? ' TRUE ' : ' FALSE '), []; 180 my $values_string = '?, 'x(scalar (@$value)-1).'?'; 181 return " ($field $mode ($values_string)) ", $value; 182 } elsif (ref($value) eq 'ARRAY') { 183 # skip empty array 184 return ($negation ? ' TRUE ' : ' FALSE '), []; 185 } elsif ( $value eq 'positive' || $value eq 'negative' ) { 186 $mode = $value eq 'positive' ? '>' : '<'; 187 return "$field $mode 0", []; 185 188 } else { 186 189 return " ($field $mode (?)) ", [$value]; 187 190 }