There is no better way that I know of, despite some hacks with beforeFind() and creating SQL out of the CDbCriteria object there, but that’s most certainly not what you want. The ProfileLogRoute really is the best way to check queries imho.
I’m actually disappointed if there’s no way to see queries during execution. I know you can use the built-in profilers, but it doesn’t help if you like to program in debug mode like I do.
I use Codeigniter for work, and it’s extremely helpful to be able to just add a $this->db->last_query() watch whenever needed.
Sorry Speeedfire.Yii Dont have any gud solution for this problem.Which i am also facing since from last 1+ year.But if your using sql statements instead of PDO or DAO statements then You can check Your Queries with var_dump.
But still its not a perfect solution for this problem.