Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘store_id’ in ‘field list’ [RESOLVED]
 
NeilA
Mentor
 
Avatar
Total Posts:  1372
Joined:  2007-09-17
Blue Mountains, Oz
 

OK, thought I had done the upgrade from 1.1.8 to 1.2.1 without error…

But when I add a new product or edit a product in Manage Products I get this error when saving:

SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘store_id’ in ‘field list’

The product is saved, so no functionality is lost, but can someone suggest a solution?

Thanks

 
Magento Community Magento Community
Magento Community
Magento Community
 
NeilA
Mentor
 
Avatar
Total Posts:  1372
Joined:  2007-09-17
Blue Mountains, Oz
 

Cause is now clear…

An extension I had installed (http://www.magentocommerce.com/extension/596/ ) is causing the SQl error.
The author has been alerted, and hopefully a fix won’t be far away.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Nexus Rex
Sr. Member
 
Avatar
Total Posts:  139
Joined:  2008-07-10
Utah, USA
 

This problem has been SOLVED.

See: http://www.magentocommerce.com/boards/viewthread/24835/#t92451

 
Magento Community Magento Community
Magento Community
Magento Community
 
NeilA
Mentor
 
Avatar
Total Posts:  1372
Joined:  2007-09-17
Blue Mountains, Oz
 

Thanks Travis…

 
Magento Community Magento Community
Magento Community
Magento Community
 
priyapriya
Jr. Member
 
Total Posts:  16
Joined:  2009-03-06
 

Hi,

I have upgraded from 1.2.1.2 to 1.3.0.
The problem is I add new attribute textbooks and set to filed author name and title.
But when I add a new product I get error like
SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘e.author_name’.
And also product is not saved.
Please guide me to correct this error.
Thanks
sanj

 
Magento Community Magento Community
Magento Community
Magento Community
 
NeilA
Mentor
 
Avatar
Total Posts:  1372
Joined:  2007-09-17
Blue Mountains, Oz
 

Sanj,
My problem (and the solution) was directly related to the extension I mention above.

* If you are not using that extension, then my solution cannot help you.
* If you are using the extension, be aware that the author has not yet upgraded it for v1.3

Regards

 
Magento Community Magento Community
Magento Community
Magento Community
 
walltoolsllc
Sr. Member
 
Total Posts:  146
Joined:  2008-08-21
 
priyapriya - 02 April 2009 12:32 AM

Hi,

I have upgraded from 1.2.1.2 to 1.3.0.
The problem is I add new attribute textbooks and set to filed author name and title.
But when I add a new product I get error like
SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘e.author_name’.
And also product is not saved.
Please guide me to correct this error.
Thanks
sanj

I am having the same problem - SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘e.whateverattribute’.  Not sure what the heck is going on, but I cannot save a product!  Arrg!  Any suggestions would be greatly appreciated.

 
Magento Community Magento Community
Magento Community
Magento Community
 
WebShopApps
Guru
 
Avatar
Total Posts:  460
Joined:  2008-05-30
London, UK
 

Hi,

Rebuild you flat product catalog in cache management. The problem is because it’s not pulled in a newly added attribute to the flat tables.

Rgds

Karen

 
Magento Community Magento Community
Magento Community
Magento Community
 
jamal.nasir
Jr. Member
 
Total Posts:  16
Joined:  2009-03-26
 
webshopapps - 29 November 2009 04:27 AM

Hi,

Rebuild you flat product catalog in cache management. The problem is because it’s not pulled in a newly added attribute to the flat tables.

Rgds

Karen

Thanks. It worked grin

 
Magento Community Magento Community
Magento Community
Magento Community
 
6thStreet
Member
 
Total Posts:  35
Joined:  2009-07-03
Baltimore, Maryland
 
zdhkw2010 - 12 July 2010 08:52 PM

hello,
I have install magento 1.4.1.0
when I login in backend it show:

SQLSTATE[42S22]Column not found1054 Unknown column 'synonym_for' in 'field list'

Trace:
#0 ../lib/Zend/Db/Statement.php(300): Zend_Db_Statement_Pdo->_execute(Array)
#1 ../lib/Zend/Db/Adapter/Abstract.php(468): Zend_Db_Statement->execute(Array)
#2 ../lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT DISTINCT...', Array)
#3 ../lib/Varien/Db/Adapter/Pdo/Mysql.php(333): Zend_Db_Adapter_Pdo_Abstract->query('SELECT DISTINCT...', Array)
#4 ../lib/Zend/Db/Adapter/Abstract.php(706): Varien_Db_Adapter_Pdo_Mysql->query(Object(Varien_Db_Select), Array)
#5 ../lib/Varien/Data/Collection/Db.php(713): Zend_Db_Adapter_Abstract->fetchAll(Object(Varien_Db_Select), Array)
#6 ../lib/Varien/Data/Collection/Db.php(626): Varien_Data_Collection_Db->_fetchAll(Object(Varien_Db_Select))
#7 ../lib/Varien/Data/Collection/Db.php(596): Varien_Data_Collection_Db->getData()
#8 ../app/code/core/Mage/Adminhtml/Block/Widget/Grid.php(484): Varien_Data_Collection_Db->load()
#9 ../app/code/core/Mage/Adminhtml/Block/Dashboard/Searches/Top.php(65): Mage_Adminhtml_Block_Widget_Grid->_prepareCollection()
#10 ../app/code/core/Mage/Adminhtml/Block/Widget/Grid.php(576): Mage_Adminhtml_Block_Dashboard_Searches_Top->_prepareCollection()
#11 ../app/code/core/Mage/Adminhtml/Block/Widget/Grid.php(582): Mage_Adminhtml_Block_Widget_Grid->_prepareGrid()
#12 ../app/code/core/Mage/Core/Block/Abstract.php(752): Mage_Adminhtml_Block_Widget_Grid->_beforeToHtml()
#13 ../app/code/core/Mage/Core/Block/Abstract.php(520): Mage_Core_Block_Abstract->toHtml()
#14 ../app/code/core/Mage/Core/Block/Abstract.php(471): Mage_Core_Block_Abstract->_getChildHtml('topSearches', true)
#15 ../app/design/adminhtml/default/default/template/dashboard/index.phtml(111): Mage_Core_Block_Abstract->getChildHtml('topSearches')
#16 ../app/code/core/Mage/Core/Block/Template.php(212): include('/webdata/webdat...')
#17 ../app/code/core/Mage/Core/Block/Template.php(239): Mage_Core_Block_Template->fetchView('adminhtml/defau...')
#18 ../app/code/core/Mage/Core/Block/Template.php(253): Mage_Core_Block_Template->renderView()
#19 ../app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
#20 ../app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Adminhtml_Block_Template->_toHtml()
#21 ../app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
#22 ../app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Core_Block_Text_List->_toHtml()
#23 ../app/code/core/Mage/Core/Block/Abstract.php(520): Mage_Core_Block_Abstract->toHtml()
#24 ../app/code/core/Mage/Core/Block/Abstract.php(471): Mage_Core_Block_Abstract->_getChildHtml('content', true)
#25 ../app/design/adminhtml/default/default/template/page.phtml(74): Mage_Core_Block_Abstract->getChildHtml('content')
#26 ../app/code/core/Mage/Core/Block/Template.php(212): include('/webdata/webdat...')
#27 ../app/code/core/Mage/Core/Block/Template.php(239): Mage_Core_Block_Template->fetchView('adminhtml/defau...')
#28 ../app/code/core/Mage/Core/Block/Template.php(253): Mage_Core_Block_Template->renderView()
#29 ../app/code/core/Mage/Adminhtml/Block/Template.php(81): Mage_Core_Block_Template->_toHtml()
#30 ../app/code/core/Mage/Core/Block/Abstract.php(753): Mage_Adminhtml_Block_Template->_toHtml()
#31 ../app/code/core/Mage/Core/Model/Layout.php(529): Mage_Core_Block_Abstract->toHtml()
#32 ../app/code/core/Mage/Core/Controller/Varien/Action.php(389): Mage_Core_Model_Layout->getOutput()
#33 ../app/code/core/Mage/Adminhtml/controllers/DashboardController.php(43): Mage_Core_Controller_Varien_Action->renderLayout()
#34 ../app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Adminhtml_DashboardController->indexAction()
#35 ../app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('index')
#36 ../app/code/core/Mage/Core/Controller/Varien/Front.php(177): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#37 ../app/code/core/Mage/Core/Model/App.php(304): Mage_Core_Controller_Varien_Front->dispatch()
#38 ../app/Mage.php(596): Mage_Core_Model_App->run(Array)
#39 ../index.php(80): Mage::run('', 'store')
#40 {main}
Can someone give me a solution?Thanks.

I ran into the same issue and just added another database column with the name “synonym_for”.

note the old table column was spelled “synonim_for” ...

running into this error on some of my templates:

SQLSTATE[42S22]Column not found1054 Unknown column 't_compare.store_id' in 'on clause'

#0 /var/www/vhosts/6thStreetShops.com/httpdocs/lib/Zend/Db/Statement.php(300): Zend_Db_Statement_Pdo->_execute(Array)
#1 /var/www/vhosts/6thStreetShops.com/httpdocs/lib/Zend/Db/Adapter/Abstract.php(468): Zend_Db_Statement->execute(Array)
#2 /var/www/vhosts/6thStreetShops.com/httpdocs/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT COUNT(DI...', Array)
#3 /var/www/vhosts/6thStreetShops.com/httpdocs/lib/Varien/Db/Adapter/Pdo/Mysql.php(333): Zend_Db_Adapter_Pdo_Abstract->query('SELECT COUNT(DI...', Array)
#4 /var/www/vhosts/6thStreetShops.com/httpdocs/lib/Zend/Db/Adapter/Abstract.php(799): Varien_Db_Adapter_Pdo_Mysql->query(Object(Varien_Db_Select), Array)
#5 /var/www/vhosts/6thStreetShops.com/httpdocs/lib/Varien/Data/Collection/Db.php(210): Zend_Db_Adapter_Abstract->fetchOne(Object(Varien_Db_Select), Array)
#6 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Catalog/Helper/Product/Compare.php(232): Varien_Data_Collection_Db->getSize()
#7 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Catalog/Model/Product/Compare/Item.php(180): Mage_Catalog_Helper_Product_Compare->calculate(true)
#8 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Core/Model/App.php(1228): Mage_Catalog_Model_Product_Compare_Item->bindCustomerLogout(Object(Varien_Event_Observer))
#9 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Core/Model/App.php(1203): Mage_Core_Model_App->_callObserverMethod(Object(Mage_Catalog_Model_Product_Compare_Item), 'bindCustomerLog...', Object(Varien_Event_Observer))
#10 /var/www/vhosts/6thStreetShops.com/httpdocs/app/Mage.php(416): Mage_Core_Model_App->dispatchEvent('customer_logout', Array)
#11 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Customer/Model/Session.php(220): Mage::dispatchEvent('customer_logout', Array)
#12 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Customer/controllers/AccountController.php(212): Mage_Customer_Model_Session->logout()
#13 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Customer_AccountController->logoutAction()
#14 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('logout')
#15 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Core/Controller/Varien/Front.php(177): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#16 /var/www/vhosts/6thStreetShops.com/httpdocs/app/code/core/Mage/Core/Model/App.php(304): Mage_Core_Controller_Varien_Front->dispatch()
#17 /var/www/vhosts/6thStreetShops.com/httpdocs/app/Mage.php(596): Mage_Core_Model_App->run(Array)
#18 /var/www/vhosts/crafts2u.com/httpdocs/index.php(52): Mage::run('c2u', 'website')
#19 {main}

looking for clues if anyone has seen on 1.4.1?

 
Magento Community Magento Community
Magento Community
Magento Community
 
chiefair
Mentor
 
Avatar
Total Posts:  1848
Joined:  2009-06-04
 

Note on above: field “synonim_for” was in table catalogsearch_query

If you’ve modified your search, you’ll need to grep “synonim_for” in your /app/code/local code storage and change them out for “synonym_for”

Just adding a field to a database to make the error go away means your search modifications will be broken…

 
Magento Community Magento Community
Magento Community
Magento Community
 
miked2004
Sr. Member
 
Avatar
Total Posts:  214
Joined:  2007-12-13
Atlanta, Georgia
 

I ran into this issue when trying to add a static product attribute to allow searching custom data from a module. I believe that the static attribute is to be stored on the entity table and not in the Entity EAV tables.

Just posting in case someone else has this issue.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Saggy
Sr. Member
 
Total Posts:  133
Joined:  2009-02-03
 

For me this was caused by the new product attributes created using sql update. I have manually save those attributes and rebuild the indexes which sorted out this problem. Hope this helps someone

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top