mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-09-04 02:22:39 +00:00
Fix greedy regex operators in Postgres driver.
`*` is greedy in regex, and needs to be escaped so that SQL operators don't cause invalid SQL conditions to be created. Refs #6877
This commit is contained in:
parent
0841c04351
commit
2f616a9e0c
2 changed files with 5 additions and 1 deletions
|
@ -98,7 +98,7 @@ class Postgres extends DboSource {
|
|||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $_sqlOps = array('like', 'ilike', 'or', 'not', 'in', 'between', '~', '~*', '!~', '!~*', 'similar to');
|
||||
protected $_sqlOps = array('like', 'ilike', 'or', 'not', 'in', 'between', '~', '~\*', '\!~', '\!~\*', 'similar to');
|
||||
|
||||
/**
|
||||
* Connects to the database using options in the given configuration array.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue