Sacado de https://community.magento.com/t5/Technical-Issues/Cannot-initialize-the-indexer-process/td-p/21640
Open app/code/local/Sm/Shopby/Model/Resource/Indexer/At
Around line 65 you will find the protected function called _getAttribute.
Change from this,
protectedfunction _getAttributes($attributeId =null){ $collection =Mage::getSingleton('eav/config') ->getEntityType(Mage_Catalog_Model_Product::ENTITY) ->getAttributeCollection() ->addFieldToFilter('`main_table`.`frontend_input`' , array('in'=> array('select','multiselect'))); if(!empty($attributeId)){ $collection->addFieldToFilter('`main_table`.`attri bute_id`', $attributeId); } return $collection; }
to this code instead,
protectedfunction _getAttributes($attributeId =null){ $collection =Mage::getSingleton('eav/config') ->getEntityType(Mage_Catalog_Model_Product::ENTITY) ->getAttributeCollection() ->addFieldToFilter('main_table.frontend_input', array('in'=> array('select','multiselect'))); if(!empty($attributeId)){ $collection->addFieldToFilter('main_table.attribut e_id', $attributeId); } return $collection; }
What changed?
The only thing I changed was removing the apostrophes (´) at lines 69 and 71. Which means that ´main_table´.´frontend_input' is now changed into main_table.frontend_input. Now the scripts updates SQL properly. Both in Admin and Shell.