I want to select only year from records ane make from this data assoc array
$wynik = $model_post::model() -> findAllBySql('SELECT DISTINCT YEAR(create_time) as rok FROM tbl_post');
for($i;$i<count($wynik);$i++)
{
$rok[$wynik[$i]->rok]=$wynik[$i]->rok;
}
but I got the exception
_Property "Post.rok" is not defined._
How can I make it correct?