Yii FindAll Tutorials

FindAll In Yii

Yii Framework. I list out all types of find, findall conditions in yii framework. It will very helpful for us.Yii find() Yii findAll()Yii findAll() JoinYii Sql commandYii find() find() <?php $model = User::model()->find(); find() With Condition <?php $model = User::model()->find('userid=1 AND status="A"'); (OR) $model = User::model()->find( 'userid=:userId And status=:Status', array(':userId'=>1,':status'=>'A') ); find() Width Criteria <?php $criteria = new CDbCriteria; $criteria->condition='userid=1 AND status="A"'; $model = User::model()->find($criteria); (OR) $criteria=new CDbCriteria; $criteria->condition='userid=:userId AND status=:Status'; […]... Read More »