Datas are not inserting into the table properly

Hi Friends,

      I installed the new version of YII (currently using 1.1.8 ).But using PHP code for my functionality from the version 1.0.7 .When I am trying to insert the data it inserted as NULL.But when I print the params values are there.Below is the code I am using Currently.

 $model=new TblTableName();

        $param=array(

                    "Column1"=>pg_escape_string(utf8_encode(trim($Column1value))),

                    "Column2"=>$Column2value,

                    "Column3"=>0,

                    "Column4"=>""

                    );

        $model->attributes=$param;

	if(!$model->validate())   // if the inputs are valid

		fputs($fp,"Not valid inputs for model");

	else

        $model->save();

With my previous version the same code works well.But for this version what I need to change.The data only inserted into the table as NULL.

Thanks in advance.

From 1.0.7 to 1.1.8 is a big jump… first step for you would be to check the "upgrade" instructions - http://www.yiiframework.com/files/UPGRADE-1.1.8.txt

Find the 1.0.7 version and read (and apply) all from there to the top of the document…