Hi everyone,
I'm stuck trying to create a many to many relation.
At that line
$t = poi::model()->with('pictures')->findByPk(2);
i get the following error:
CDbCommand failed to execute the SQL statement: SQLSTATE[42S22]: Column not found: 1054 Unknown column 't2.' in 'on clause'
I have a table poi which has a MANY to MANY relation to Picture, through the table poi_x_picture.
In POI I have the following relation:
'pictures' => array(self::MANY_MANY, 'Picture', 'poi_x_picture(id_poi, id_picture)')
Please, help