Skip to content
This repository was archived by the owner on Oct 2, 2019. It is now read-only.

Commit a0cb19f

Browse files
author
msavich
committed
Zend_Db_Select v 1.12.9 changes reverted due to backward incompatibility
1 parent d1ab66b commit a0cb19f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

library/Zend/Db/Select.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,7 @@ public function group($spec)
509509
}
510510

511511
foreach ($spec as $val) {
512-
if (preg_match('/^[\w]*\([^\)]*\)$/', (string) $val)) {
512+
if (preg_match('/\(.*\)/', (string) $val)) {
513513
$val = new Zend_Db_Expr($val);
514514
}
515515
$this->_parts[self::GROUP][] = $val;
@@ -601,7 +601,7 @@ public function order($spec)
601601
$val = trim($matches[1]);
602602
$direction = $matches[2];
603603
}
604-
if (preg_match('/^[\w]*\([^\)]*\)$/', $val)) {
604+
if (preg_match('/^[\w]*\(.*\)$/', $val)) {
605605
$val = new Zend_Db_Expr($val);
606606
}
607607
$this->_parts[self::ORDER][] = array($val, $direction);
@@ -943,7 +943,7 @@ protected function _tableCols($correlationName, $cols, $afterCorrelationName = n
943943
$alias = $m[2];
944944
}
945945
// Check for columns that look like functions and convert to Zend_Db_Expr
946-
if (preg_match('/^[\w]*\([^\)]*\)$/', $col)) {
946+
if (preg_match('/\(.*\)/', $col)) {
947947
$col = new Zend_Db_Expr($col);
948948
} elseif (preg_match('/(.+)\.(.+)/', $col, $m)) {
949949
$currentCorrelationName = $m[1];

0 commit comments

Comments
 (0)