Permalink
Browse files

Fixes #2048: AR now uses alias from CActiveRecord::getTableAlias ins…

…tead of always using default "t"
  • Loading branch information...
samdark committed Mar 5, 2013
1 parent f0613e5 commit 356c00247e120e818c3426d0ca0cc866e2083b4b
Showing with 2 additions and 1 deletion.
  1. +1 −0 CHANGELOG
  2. +1 −1 framework/db/ar/CActiveRecord.php
View
@@ -17,6 +17,7 @@ Version 1.1.14 work in progress
- Bug #1997: Cache key in CGettextMessageSource::loadMessages wasn't specific enough (odevyatkov)
- Bug #2023: CHttpRequest::stripSlashes() now modifies array keys as well (etienneq)
- Bug #2030: Fixed problem with MySQL 4.x: Undefined Index: Comment in CMysqlSchema (cebe)
+- Bug #2048: AR now uses alias from CActiveRecord::getTableAlias instead of always using default "t" (s-larionov)
- Bug #2049: CStatElement relation with join option throw exception when key-field present on joined table (Yiivgeny)
- Bug #2078: Fixed problem with "undefined" parameter in query string when using CListView or CGridView with enableHistory (Parpaing)
- Bug #2086: Fixed .hgignore rule for assets folder (GeXu3, Koduc)
@@ -1294,7 +1294,7 @@ protected function query($criteria,$all=false)
{
if(!$all)
$criteria->limit=1;
- $command=$this->getCommandBuilder()->createFindCommand($this->getTableSchema(),$criteria,$this->getTableAlias(false));
+ $command=$this->getCommandBuilder()->createFindCommand($this->getTableSchema(),$criteria,$this->getTableAlias());
return $all ? $this->populateRecords($command->queryAll(), true, $criteria->index) : $this->populateRecord($command->queryRow());
}
else

0 comments on commit 356c002

Please sign in to comment.