Open hazzy opened 5 years ago
Please can you help me I have installed Magmi-M2 on magento 2.3 and I get the below error. How did you fix it to get it to start importing products.
Fatal error: Uncaught PDOException: SQLSTATE[HY000] [1045] Access denied for user ''@'localhost' (using password: NO) in /home/aikigailifecom/public_html/magmi/inc/dbhelper.class.php:58 Stack trace: #0 /home/aikigailifecom/public_html/magmi/inc/dbhelper.class.php(58): PDO->__construct('mysql:host=loca...', NULL, NULL, Array) #1 /home/aikigailifecom/public_html/magmi/inc/magmi_engine.php(518): DBHelper->initDb('localhost', 'magento', NULL, NULL, '3306', NULL, 'net', false) #2 /home/aikigailifecom/public_html/magmi/plugins/base/general/reindex/magmi_reindexing_plugin.php(35): Magmi_Engine->connectToMagento() #3 /home/aikigailifecom/public_html/magmi/plugins/base/general/reindex/magmi_reindexing_plugin.php(105): Magmi_ReindexingPlugin->initIndexList() #4 /home/aikigailifecom/public_html/magmi/plugins/base/general/reindex/options_panel.php(20): Magmi_ReindexingPlugin->getIndexList() #5 /home/aikigailifecom/public_html/magmi/plugins/inc/magmi_plugin.php(95): require('/home/aikigaili...') #6 /home/aikigailifecom/public_html/mag in /home/aikigailifecom/public_html/magmi/inc/dbhelper.class.php on line 58
Hi @hazzy Are you sure you're using branch "magento 2" or a tag > 200.7.0 ? I don;t see any reference to this table in our code, so most probably you're still using magmi for magento 1, which will not work
@tmotyl Thanks for your reply.
But can you please check for me - i can see line 242 in magmi-m2/magmi/plugins/base/itemprocessors/configurables/magmi_configurableprocessor.php
$cpsap = $this->tablename("catalog_product_super_attribute_pricing");
also line 28 in magmi-m2/magmi/plugins/utilities/clearproductsandcategories/clearproductsandcategories.php
// "catalog_product_link_attribute",
// "catalog_product_link_type",
"catalog_product_option","catalog_product_option_price","catalog_product_option_title",
"catalog_product_option_type_price","catalog_product_option_type_title","catalog_product_option_type_value",
"catalog_product_super_attribute","catalog_product_super_attribute_label",
"catalog_product_super_attribute_pricing","catalog_product_super_link","catalog_product_enabled_index",
Am i looking at the wrong code somehow??
ah, you're right, somehow the ide tricked me. Please send a PR once you figure out how to fix it.
@tmotyl I would love to do that but don't have the required skills - sorry.
Do we know who reported this plugin as working? Maybe they might have something to add
@hazzy it's not really the plugin's issue. You can just remove super_attribute_pricing
from the csv you're importing and the issue will go away. That table doesn't exist anymore because Magento 2 doesn't handle configurable products in the same way as Magento 1. You can associate simple products with the configurable by just adding a column name simples_skus
to your csv and putting a comma separated list of skus you like to be associated with the configurable product. The simples_skus
column should be empty if the product on that row isn't a configurable. Note, make sure you have all those simple products in the csv above the configurable you want to associate them with otherwise you may get an error related to Magmi not finding the simple skus.
Here's a screenshot example of what I'm talking about regarding the simples_skus
column
@NateSwanson7 Thanks very much for the info! I will do as you suggest in a test and report back.
@NateSwanson7 Thanks very much for the info! I will do as you suggest in a test and report back.
@hazzy Yep, just let me know if you need any additional help. I'm a developer and I've been setting up and configuring Magmi to work with my company's instance of Magento 2. So I've created a custom plugin to import product videos and setup some different configurations to allow us to use the same csv files we used in M1. I feel pretty confident about helping others with Magmi issues for M2 because I've probably already experienced them.
@NateSwanson7 Just a quick update to let you know your suggestion above fixed my issue. Thanks very much!
Did you see my other issue #70 by any chance. Maybe you might have an idea on that one?
@hazzy I hadn't seen the issue you mentioned. That looks like it may be a Magento issue more so than a Magmi issue. If you have a development site setup, I'd try deleting that product (Product ID 235) then reimport that product using Magmi and see if you still get the same error.
I am testing Magmi-M2 on a database migrated from Magento V1 using the Magento Migration tool.
I am running Magmi_ConfigurableItemProcessor and am getting the following errors for every Sku suggesting the “catalog_product_super_attribute_pricing'” does not exist. :
…..
Indeed “catalog_product_super_attribute_pricing'” does not exist and is not shown in the Magento M2 Schema diagram. So i assume the code should not reference it at all.
Can anyone shed some light on this issue please as I have seen it stated the plugin should work ok.
Thanks.
John