Issues

ZF-12546: Error while accessing the database

Issue Type: Bug Created: 2013-03-20T10:20:54.000+0000 Last Updated: 2013-03-20T10:47:00.000+0000 Status: Closed Fix version(s): Reporter: krishna aditya (aditya) Assignee: None Tags: - Zend_Db

Related issues: Attachments:

Description

Message: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'EMPLOYEE_ID' in 'order clause' Stack trace:

0 /var/www/Employee/library/Zend/Db/Statement.php(300): Zend_Db_Statement_Pdo->_execute(Array)

1 /var/www/Employee/library/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)

2 /var/www/Employee/library/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query(Object(Zend_Db_Table_Select), Array)

3 /var/www/Employee/library/Zend/Db/Table/Abstract.php(1529): Zend_Db_Adapter_Pdo_Abstract->query(Object(Zend_Db_Table_Select))

4 /var/www/Employee/library/Zend/Db/Table/Abstract.php(1344): Zend_Db_Table_Abstract->_fetch(Object(Zend_Db_Table_Select))

5 /var/www/Employee/application/models/EmployeeMapper.php(30): Zend_Db_Table_Abstract->fetchAll(Object(Zend_Db_Table_Select))

6 /var/www/Employee/application/controllers/EmployeeController.php(21): Application_Model_EmployeeMapper->fetchAll()

7 /var/www/Employee/library/Zend/Controller/Action.php(516): EmployeeController->indexAction()

8 /var/www/Employee/library/Zend/Controller/Dispatcher/Standard.php(295): Zend_Controller_Action->dispatch('indexAction')

9 /var/www/Employee/library/Zend/Controller/Front.php(954): Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http))

10 /var/www/Employee/library/Zend/Application/Bootstrap/Bootstrap.php(97): Zend_Controller_Front->dispatch()

11 /var/www/Employee/library/Zend/Application.php(366): Zend_Application_Bootstrap_Bootstrap->run()

12 /var/www/Employee/public/index.php(27): Zend_Application->run()

13 {main}

Request Parameters:

array ( 'controller' => 'employee', 'action' => 'index', 'module' => 'default', )

Comments

Posted by Frank Brückner (frosch) on 2013-03-20T10:44:20.000+0000

This is a problem in your own code and not a bug in ZF!

Please recheck your code and search for the method call order. (Compare with the docs)

Posted by Frank Brückner (frosch) on 2013-03-20T10:47:00.000+0000

For more questions please use the mailing lists or Stackoverflow.

Have you found an issue?

See the Overview section for more details.

Copyright

© 2006-2016 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.

Contacts