* $user = Yii::app()->db->createCommand() * ->select('username, password') * ->from('tbl_user') * ->where('id=:id', array(':id'=>1)) * ->queryRow(); *
'SELECT * FROM tbl_user'
array('select'=>'*', 'from'=>'tbl_user')
array(':name'=>'John', ':age'=>25)
array(operator, operand1, operand2, ...)
and
or
in
not in
like
not like
or like
or not like
* $criteria->order('(1)'); *
$columns