I’m looking for a way to execute two database commands at each database connection.
One of the commands must contain the authenticated user’s name.
CDbConnection’s initSQLs looks like the answer, but I’m having trouble finding the right place to add to initSQLs, i.e., some time after Yii::app()->user->name is set.
CWebUser::afterLogin doesn’t work, as it only fires on the initial login.