forked from extern/egroupware
(partial) backport of 33571 to fix case-sensitive like and infinite loop with OR
This commit is contained in:
parent
1e57dc6cf8
commit
052d31c168
@ -1115,6 +1115,7 @@ class so_sql
|
|||||||
}
|
}
|
||||||
elseif ($token == strtoupper(lang('OR')) || $token == 'OR')
|
elseif ($token == strtoupper(lang('OR')) || $token == 'OR')
|
||||||
{
|
{
|
||||||
|
$token = strtok($break);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
elseif ($token == strtoupper(lang('NOT')) || $token == 'NOT')
|
elseif ($token == strtoupper(lang('NOT')) || $token == 'NOT')
|
||||||
@ -1159,7 +1160,7 @@ class so_sql
|
|||||||
$op = 'OR';
|
$op = 'OR';
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
$token_filter = " $columns LIKE " .
|
$token_filter = " $columns " . $this->db->capabilities['case_insensitive_like'] . ' ' .
|
||||||
$GLOBALS['egw']->db->quote($wildcard.str_replace(array('%','_','*','?'),array('\\%','\\_','%','_'),$token).$wildcard);
|
$GLOBALS['egw']->db->quote($wildcard.str_replace(array('%','_','*','?'),array('\\%','\\_','%','_'),$token).$wildcard);
|
||||||
|
|
||||||
// Compare numeric token as equality for numeric columns
|
// Compare numeric token as equality for numeric columns
|
||||||
|
Loading…
Reference in New Issue
Block a user