MINOR Fixed syntax errors from SQLQuery/DataQuery cleanup

This commit is contained in:
Ingo Schommer 2012-05-16 13:17:19 +02:00
parent 4da9e72eed
commit 8f2ede8fcf
2 changed files with 5 additions and 5 deletions

View File

@ -325,7 +325,7 @@ class DataQuery {
* @param String $field Unquoted database column name (will be escaped automatically)
*/
function Max($field) {
return $this->getFinalisedQuery()->aggregate(sprintf('MAX("%s")', Convert::raw2sql($field))->execute()->value();
return $this->getFinalisedQuery()->aggregate(sprintf('MAX("%s")', Convert::raw2sql($field)))->execute()->value();
}
/**
@ -334,7 +334,7 @@ class DataQuery {
* @param String $field Unquoted database column name (will be escaped automatically)
*/
function Min($field) {
return $this->getFinalisedQuery()->aggregate(sprintf('MIN("%s")', Convert::raw2sql($field))->execute()->value();
return $this->getFinalisedQuery()->aggregate(sprintf('MIN("%s")', Convert::raw2sql($field)))->execute()->value();
}
/**
@ -343,7 +343,7 @@ class DataQuery {
* @param String $field Unquoted database column name (will be escaped automatically)
*/
function Avg($field) {
return $this->getFinalisedQuery()->aggregate(sprintf('AVG("%s")', Convert::raw2sql($field))->execute()->value();
return $this->getFinalisedQuery()->aggregate(sprintf('AVG("%s")', Convert::raw2sql($field)))->execute()->value();
}
/**
@ -352,7 +352,7 @@ class DataQuery {
* @param String $field Unquoted database column name (will be escaped automatically)
*/
function Sum($field) {
return $this->getFinalisedQuery()->aggregate((sprintf('SUM("%s")', Convert::raw2sql($field)))->execute()->value();
return $this->getFinalisedQuery()->aggregate(sprintf('SUM("%s")', Convert::raw2sql($field)))->execute()->value();
}
/**

View File

@ -848,7 +848,7 @@ class SQLQuery {
else $filter = "(" . implode(") AND (", $join['filter']) . ")";
$aliasClause = ($alias != $join['table']) ? " AS \"" . Convert::raw2sql($alias) . "\"" : "";
$this->from[$alias] = strtoupper($join['type']) . " JOIN \"{" . Convert::raw2sql($join['table']) . "}\"$aliasClause ON $filter";
$this->from[$alias] = strtoupper($join['type']) . " JOIN \"" . Convert::raw2sql($join['table']) . "\"$aliasClause ON $filter";
}
}