yiisoft/yii — pull request #3557 by pvolyntsev (2014-09-28 19:05:54+00:00)
Title: Reduce database usage

Sample:

$command = Yii::app()->db->cache(60)->createCommand("SELECT * FROM some_table LIMIT 10");

This opens database connection even if ```Yii::app()->db->autoConnect=false``` and query results are already in cache.

I moved CDbConnection::setActive(true) from CDbConnection::createCommand() to CDbCommand::getConnection().