Friday, September 21, 2012

Magento : Integrity constraint violation Column in where clause is ambiguous

Generally, This types of error come, when we are using join query or custom module 
Add ‘filter_index’=>’main_table.column_name’ in $this->addColumn() function

As
$this->addColumn('column_name', array(
'header' => Mage::helper('module')->__('Column Value'),
'align' =>'left',
'index' => 'column_name',
'filter_index'=>'main_table.column_name', // This parameter helps to resolve above error
));

No comments:

Post a Comment