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

the quest for an efficient product import script
 
zuiko
Guru
 
Avatar
Total Posts:  304
Joined:  2009-02-06
Nantes France
 
shmk - 06 September 2012 06:53 AM

What is the “correct” method to import this kind of situation with magmi?

I would propose, to import in shop admin in creation mode in Magmi a first complete file with text in your default language.
This will impose the default product content.
Thus to import in the other language shop in update mode in Magmi with just the attributes to translate as columns.

I proceed like this and it works…

 
Magento Community Magento Community
Magento Community
Magento Community
 
shmk
Sr. Member
 
Total Posts:  297
Joined:  2009-10-28
 
zuiko - 12 September 2012 01:28 PM

I would propose, to import in shop admin in creation mode in Magmi a first complete file with text in your default language.
This will impose the default product content.
Thus to import in the other language shop in update mode in Magmi with just the attributes to translate as columns.

I proceed like this and it works…

Thank you.

For the imports next to the first, an “update” with all the fields in default language and then with 2nd language with just the columns would work? Or the first have to be always in “creation” mode?

 
Magento Community Magento Community
Magento Community
Magento Community
 
rathna
Jr. Member
 
Total Posts:  4
Joined:  2012-05-09
 

Hi, I really hope someone can help me on this as I am losing my sleep over and pulling my hair out.

1. I have the add on Import + Export Bulk Product Attributes / Attribute Sets / Attribute Options / Multiple Attributes which I use to import attributes
2. I am using magmi to import products with on the fly cats and hoping to create attrib option values

Attached file contains the data I used. Attributes in first two rows and the other two rows are product header and product data row. uploaded here as a single file.

My problem is magmi is not adding attrib option values in the magento attribute and there by adding to the product. I tried multiple instances clean installs so many times but i am getting the same result.

I know i am missing something simple but crucial here so if any one can look at these files and let me know what I am missing I will owe them big time! please help!

thanks
Rathna

File Attachments
attribs and products.xls  (File Size: 25KB - Downloads: 75)
 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

i can see for your specific attribute frontend_input “select” and backend_type “text” ????? , that’s weird i think.
Weird enough for magmi not being able to know what to do with it.
It it’s a text in backend, then it’s not an option list. (and magmi will fill text)
it it’s an option list, backend type for this attribute has to be set as any other standard option list , ie : int (since even if text values are stored for it, they are considered as indexed options)

 
Magento Community Magento Community
Magento Community
Magento Community
 
rathna
Jr. Member
 
Total Posts:  4
Joined:  2012-05-09
 

Thank you Dweeves!! it worked. why didnt I post my question here earlier! I was cracking my head over this for a whole 3 days! I cant thank you enough. so basically by default that column should be int if the other one is select so it will appear in the layered navigation, correct?

I have another question here. do you have any benchmark data for magmi? I uploaded about 250K products with 950 attributes (as text!) and it took me 3 days on my laptop with a core i5 and a SSD drive. The only plugin i am using right now is on the fly category creator although I will be using image processor later. any ideas how i can minimize the time it takes to load?

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

You should have selected magmi optimizer plugin. Especially having lots of option list since for them magmi needs to perform find by value requests in eav tables. This plugin just adds some extra indexes in magento eav tables. Moreover, for such big data, 950 attributes!!! over a non neglictible number of products, database tuning is not an option.

 
Magento Community Magento Community
Magento Community
Magento Community
 
tomharding
Member
 
Avatar
Total Posts:  63
Joined:  2011-03-24
 

Hi Dweeves,

I’m attempting to import products which total up to the thousands - they import fine (a few of them have things missing, but that’s expected when you import that number)

The problem I’m having is, is that the tax class id is always set to ‘none’. I’ve tried to import them with tax_class_id set to ‘2’ and ‘Taxable Goods’, but they always set to 0. Weird thing is that I’ve used Magmi for other installations and it’s worked ok.

I should say that I’m using the mysql import as opposed to the csv import. Got a feeling that could be an issue in itself. It’s also a magento 1.7.

Is there anything I’m missing out on here?

Cheers smile
Tom

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

magmi uses tax_class name in the tax_class_id column (as legacy dataflow in fact) but will import it into product using the id of the tax class name in the tax_class table (which is expected in the product structure)

if magmi sets it to 0 , then it did not found the tax class name in the tax_class table.
see the code of getTaxClassId in magmi_productimportengine.php , that’s all it does.

so i would enjoin you to check what are the tax class names in your tax_class table in magento db and set your tax_class_id values accordingly.

maybe you did not create tax classes or some of their names changed in the magento admin.

 
Magento Community Magento Community
Magento Community
Magento Community
 
kiwimagent
Jr. Member
 
Total Posts:  3
Joined:  2012-07-29
 
\"nicolas95\" -

With the following code on one line:

|store|,|sku|,|categories|
|
admin ,ebayfreavantagefr amazonfr priceministerfr pixplacefr fnacfr xmoinscherfr|,|3DX_700026|,|[e-Avantage]/Périphériques Informatiques/Saisie/Souris 3D;;Périphériques Informatiques/Saisie/Souris;;|[eBay]/Périphériques Informatiques/Saisie/Souris 3D|

I have an error Magmi

On the fly category creator/importer v0.1.7 Cannot find site root with name e-Avantage]/Périphériques Informatiques/Saisie/Souris 3D;;Périphériques Informatiques/Saisie/Souris;;[eBay

Dweeves replied:

\"dweeves\" -

interesting bug in regexp capturing of categories module wink

i\’ll make a fix ASAP , in your sample there should however not have any | before the [eBay] root.

Hi - I noticed there are about 3 posts in the forum relating to this issue.  I was wondering whether I am missing a solution.  I have read the wiki and tried a few different things, am using the latest release, etc., but in general find:

This works as expected in the categories column:  [root1]/level1/level2/level3

But this doesn\’t work in the categories column:  [root1]/level1/level2/level3;;[root2]/levela/levelb/levelc it yields the following error: \"On the fly category creator/importer v0.1.7 - Cannot find site root with name : root1]/level1/level2/level3;;[root2\”

Anything I\’m missing?  Any help much appreciated.

 
Magento Community Magento Community
Magento Community
Magento Community
 
dweeves
Enthusiast
 
Total Posts:  877
Joined:  2010-06-26
FRANCE
 

i found the bug,

line 315 & 287 of magmi/plugin/extra/itemprocessors/categories/categoryimport.php

replace

if(preg_match("|^\[(.*)?\].*$|",...

by :

if(preg_match("|^\[(.*?)\].*$",...

that should work better, in fact a misplaced question mark.

 
Magento Community Magento Community
Magento Community
Magento Community
 
kiwimagent
Jr. Member
 
Total Posts:  3
Joined:  2012-07-29
 
dweeves - 25 September 2012 01:29 AM

i found the bug,

line 315 & 287 of magmi/plugin/extra/itemprocessors/categories/categoryimport.php

replace

if(preg_match("|^\[(.*)?\].*$|",...

by :

if(preg_match("|^\[(.*?)\].*$",...

that should work better, in fact a misplaced question mark.

Thanks Dweeves - that certainly takes care of the regexp issue! smile Unfortunately still not getting the desired result on the category insert though.  For example:  categories entry:  [root1]/level1/level2;;[root2]/levela/levelb yields the following:

[root1 (existing root)]
+level1
++level2
+[root2] (this is created verbatim “[root2]” as a subcategory of root1 and theoretically shouldn’t be)
++levela
+++levelb
[root2 (existing root)]

Ideally, this would have yielded:

[root1 (existing root)]
+level1
++level2
[root2 (existing root)]
+levela
++levelb

Any ideas?  Thanks so much for your help!

EDIT: edited indents in above example to make effect clear.

 
Magento Community Magento Community
Magento Community
Magento Community
 
kiwimagent
Jr. Member
 
Total Posts:  3
Joined:  2012-07-29
 

Update: I’ve looked through the code in categoryimport.php (to the best of my limited ability) and it seems like things are currently set up to handle assignment of skus/categories to one explicit root at a time.

e.g., in the categories field [root1]/a/b;;/c/d;;e/f results in:

[root1]
+a
++b
+c
++d
+e
++f

but [root1]/a/b;;/c/d;;e/f;;[root2]/u/v;;/w/x;;y/z won’t produce:

[root1]
+a
++b
+c
++d
+e
++f
[root2]
+u
++v
+w
++x
+y
++z

To add to additional categories in different roots (and/or create those categories), an update using category_reset set to 0 seems to be the best approach. So create ... then update wink.

Thanks for a great piece of software Dweeves ... looks like it may be very useful!

 
Magento Community Magento Community
Magento Community
Magento Community
 
rathna
Jr. Member
 
Total Posts:  4
Joined:  2012-05-09
 

is anyone having problem importing products in csv format (I have separator selected as comma and double quote as encloser)? Magmi is complaining that the columns dont match as the manufacturer is listed as “ABC, Inc.”. it include the comma and says the data has more columns than the header and skips the row

 
Magento Community Magento Community
Magento Community
Magento Community
 
Stanley01
Jr. Member
 
Total Posts:  1
Joined:  2012-02-29
 

Thanks for this great plugin! I have succesfully imported a (headerless)CSV file of my client. I mapped the column’s and it is all working like expected, except for the ‘categories’ attribute. My CSV file uses a column with category names like “Network Routers” and “Extra Products”. When i map the attribute “categories” or “category” to this row, the imported products don’t get a category assigned to them. Is there a way to get this working?

I also tried adding ‘category_ids’ by hand, this worked, but the problem is my CSV doesn’t use cat id’s it uses cat names. Does anyone have an idea where i can start?

Thanks in advance!

 
Magento Community Magento Community
Magento Community
Magento Community
 
rathna
Jr. Member
 
Total Posts:  4
Joined:  2012-05-09
 

when saving the profile the linux php(?) adds a \ slash n the front of double quote. if i manually edit the conf file and remove the slash then it work. now another problem:

when saving mysql outfile with double quote as encloser, if the item has a double quote inside then it escapes it with a back slash which is imported as it is by magmi!

so a product exported by msql looks like this “ABC 17\” screen” shows in magento after import with magmi as ABC 17\” screen. how do i fix this Dweeves or any one?

thanks!

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