Hey!..I’m new in Yii framework so how to retrieve one field only in database… ![]()
Hey!..I’m new in Yii framework so how to retrieve one field only in database… ![]()
Hey!..I’m new in Yii framework, so how to retrieve one field only in database and display in index page. ![]()
Please read the guide and use forum search to find the solution for your very basic task.
$value = Yii::app()->db->createCommand( ‘SELECT field FROM table’ )->queryScalar();
[color="#008000"]NOTE: merged duplicate posts[/color]