CgridView through several relation


I follow this guide to create a cgridview allowing to searching and sorting related model:

Here are my relations:

license BELONGS_TO install

install BELONGS_TO node

I can by this way create a CGridview with any field of my license and install models. However, I can have fields of the node model, But I have the following error when searching on it:

I don’t understand, my table node is linked in my search fuction.

Here is my CGridview on model license:

$this->widget('zii.widgets.grid.CGridView', array(


















And my my license model:

public $siteId_search;

public $installId_search;


public function search()


	// Warning: Please modify the following code to remove attributes that

	// should not be searched.

	$criteria=new CDbCriteria;

        $criteria->with=array('install.node', 'install.product');           


        $criteria->compare( 'install.node.f_site_id', $this->siteId_search, true );


        $criteria->compare( 'install.f_install_id', $this->installId_search, true );



	return new CActiveDataProvider('t_licence', array(




Any Idea? You can see that my search function also call table install.product, I have the same problem on it.


It was a silly thing, I just had to change this

$criteria->compare( 'install.node.f_site_id', $this->siteId_search, true );


$criteria->compare( 'node.f_site_id', $this->siteId_search, true );

in my search()