brankoajzele / B05032-Foggyline_Office

17 stars 9 forks source link

how to solve this error #3

Open daicooper opened 8 years ago

daicooper commented 8 years ago

hello ,I paste the code to my magento test project , but when I use the command 'magento setup:upgrade ', it doesn't work well ,the feedback is "
[Zend_Db_Adapter_Exception]
No host configured to connect " . at the same time, I foud there are have seven new tables added to my database, “foggyline_office_department”, "foggyline_office_employee_entity", "foggyline_office_employee_entity_datetime", "foggyline_office_employee_entity_decimal", "foggyline_office_employee_entity_int", "foggyline_office_employee_text", "foggyline_office_employee_entity_varchar", and only "foggyline_office_department" table has one record "entity_id =1, name=Sale", others table are empty . I think it may be works wrong when the system running "Upgradedata.php" . but i don't konw how to solve it . can you help ?thanks!

the error: Data install/update: Module 'Allen_HelloWorld': Module 'Allen_SampleModifyContent': Module 'CyberZend_SocialLogin': Module 'Magento_Store': Module 'Magento_AdminNotification': Module 'Magento_AdvancedPricingImportExport': Module 'Magento_Directory': Module 'Magento_Theme': Module 'Magento_Backend': Module 'Magento_Backup': Module 'Magento_Eav': Module 'Magento_Indexer': Module 'Magento_BundleImportExport': Module 'Magento_CacheInvalidate': Module 'Magento_Customer': Module 'Magento_Cms': Module 'Magento_CatalogImportExport': Module 'Magento_Catalog': Module 'Magento_Rule': Module 'Magento_Msrp': Module 'Magento_Search': Module 'Magento_CatalogUrlRewrite': Module 'Magento_Widget': Module 'Magento_Quote': Module 'Magento_CheckoutAgreements': Module 'Magento_SalesSequence': Module 'Magento_CmsUrlRewrite': Module 'Magento_Config': Module 'Magento_ConfigurableImportExport': Module 'Magento_Payment': Module 'Magento_Contact': Module 'Magento_Cookie': Module 'Magento_Cron': Module 'Magento_CurrencySymbol': Module 'Magento_Bundle': Module 'Magento_CustomerImportExport': Module 'Magento_Deploy': Module 'Magento_Developer': Module 'Magento_Dhl': Module 'Magento_Authorization': Module 'Magento_Downloadable': Module 'Magento_ImportExport': Module 'Foggyline_Office': Installing data... Upgrading data...

[Zend_Db_Adapter_Exception]
No host configured to connect

setup:upgrade [--keep-generated] [--magento-init-params="..."]

Fatal error: Uncaught exception 'Exception' with message 'User Error: Some transactions have not been committed or rolled back in /opt/lampp/apps/magento/htdocs/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php on line 3774' in /opt/lampp/apps/magento/htdocs/vendor/magento/framework/App/ErrorHandler.php:61 Stack trace:

0 [internal function]: Magento\Framework\App\ErrorHandler->handler(256, 'Some transactio...', '/opt/lampp/apps...', 3774, Array)

1 /opt/lampp/apps/magento/htdocs/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php(3774): trigger_error('Some transactio...', 256)

2 [internal function]: Magento\Framework\DB\Adapter\Pdo\Mysql->__destruct()

3 {main}

thrown in /opt/lampp/apps/magento/htdocs/vendor/magento/framework/App/ErrorHandler.php on line 61

anarbayramov commented 8 years ago

Hello I'm having exactly same problem too have you managed to fix it ?

gianisimone commented 7 years ago

same error for me.. It seems to be related to the UpgradeData class, when it tries to call the save method on \Foggyline\Office\Model\EmployeeFactory $employee object. Anyone has solved this issue?

gianisimone commented 7 years ago

Found a solution. It seems a problem related to eav cache. Disabling eav cache from env.php makes the upgrade run fine. See this http://magento.stackexchange.com/questions/126635/magento2-upgrade-data-script-for-custom-module

thdoan commented 7 years ago

I have EAV cache dsiabled, but still getting this error, which is preventing people from saving new color swatches. Any other ideas?

maile-it-solutions commented 6 years ago

check if you have EmployeeSetup.php in app/code/Foggyline/Office/Setup.

useapp commented 6 years ago

Hello I'm having exactly same problem too Magento 2.1.9 'eav' => 0

imanasmage commented 5 years ago

I'm also facing the same problem when I generating shipment from admin Fatal error: Uncaught exception 'Exception' with message 'User Error: Some transactions have not been committed or rolled back in /vendor/magento/framework/DB/Adapter/Pdo/Mysql.php on line 3767' in /vendor/magento/framework/App/ErrorHandler.php:61 Stack trace: #0 [internal function]: Magento\Framework\App\ErrorHandler->handler(256, 'Some transactio...', '/...', 3767, Array) #1 /vendor/magento/framework/DB/Adapter/Pdo/Mysql.php(3767): trigger_error('Some transactio...', 256) #2 [internal function]: Magento\Framework\DB\Adapter\Pdo\Mysql->__destruct() #3 {main} thrown in /vendor/magento/framework/App/ErrorHandler.php on line 61