Make sure we don't quote column names twice

This commit is contained in:
Joas Schilling 2016-02-23 08:50:52 +01:00
parent 4dfdb2720c
commit 8754ea6c8a
3 changed files with 3 additions and 3 deletions

View File

@ -33,7 +33,7 @@ class MySqlExpressionBuilder extends ExpressionBuilder {
public function iLike($x, $y, $type = null) {
$x = $this->helper->quoteColumnName($x);
$y = $this->helper->quoteColumnName($y);
return $this->comparison($x, ' COLLATE utf8_general_ci LIKE', $y);
return $this->expressionBuilder->comparison($x, ' COLLATE utf8_general_ci LIKE', $y);
}
}

View File

@ -156,6 +156,6 @@ class OCIExpressionBuilder extends ExpressionBuilder {
public function iLike($x, $y, $type = null) {
$x = $this->helper->quoteColumnName($x);
$y = $this->helper->quoteColumnName($y);
return 'REGEXP_LIKE(`'.$x.'`, \'^\' || REPLACE('.$y.', \'%\', \'.*\') || \'$\', \'i\')';
return new QueryFunction('REGEXP_LIKE('.$x.', \'^\' || REPLACE('.$y.', \'%\', \'.*\') || \'$\', \'i\')');
}
}

View File

@ -49,7 +49,7 @@ class PgSqlExpressionBuilder extends ExpressionBuilder {
public function iLike($x, $y, $type = null) {
$x = $this->helper->quoteColumnName($x);
$y = $this->helper->quoteColumnName($y);
return $this->comparison($x, 'ILIKE', $y);
return $this->expressionBuilder->comparison($x, 'ILIKE', $y);
}
}