[2.0] Reverted r7392 which generates broken SQL query.
This commit is contained in:
parent
bb94f6ea7c
commit
29e5141280
@ -2129,7 +2129,7 @@ class Parser
|
||||
/**
|
||||
* ArithmeticPrimary ::= SingleValuedPathExpression | Literal | "(" SimpleArithmeticExpression ")"
|
||||
* | FunctionsReturningNumerics | AggregateExpression | FunctionsReturningStrings
|
||||
* | FunctionsReturningDatetime | ResultVariable
|
||||
* | FunctionsReturningDatetime | IdentificationVariable
|
||||
*/
|
||||
public function ArithmeticPrimary()
|
||||
{
|
||||
@ -2154,7 +2154,7 @@ class Parser
|
||||
return $this->SingleValuedPathExpression();
|
||||
}
|
||||
|
||||
return $this->ResultVariable();
|
||||
return $this->IdentificationVariable();
|
||||
|
||||
case Lexer::T_INPUT_PARAMETER:
|
||||
return $this->InputParameter();
|
||||
|
@ -1640,9 +1640,7 @@ class SqlWalker implements TreeWalker
|
||||
} else if ($primary instanceof AST\Node) {
|
||||
$sql .= $primary->dispatch($this);
|
||||
} else if (is_string($primary)) {
|
||||
$columnName = $this->_queryComponents[$primary]['token']['value'];
|
||||
|
||||
$sql .= $this->_scalarResultAliasMap[$columnName];
|
||||
// We need to deal with IdentificationVariable here
|
||||
}
|
||||
|
||||
return $sql;
|
||||
|
Loading…
Reference in New Issue
Block a user