Error: SQLSTATE [23000]: Integrity constraint violation: 1052 Column 'hoge_id' in where clause is ambiguous
PDOException
Error: SQLSTATE [23000]: Integrity constraint violation: 1052 Column 'hoge_id' in where clause is ambiguous
みたいなエラーがでた。
controllerでデータベースを指定してなかった。
{テーブル名}.hoge_id
にするか、そのテーブルのカラムなら$this->aliasField('hoge_id')
にすると直った