0
votes

I have a webshop with some categories in my root folder. Root categorie - Home - Toys - Accessoires - Bricks etc

From my manufacturer i can download every night a csv file with categoryname1/categoryname2/categoryname3/categoryname4 etc.

What i want to do is the following: If categoryname1 equals "toys" then Magmi must make the categoryname under my already existing category "Toys". Also al the products from the csv file in the categoryname1 column must be imported and assigned to the right category in Magento.

I also want to exclude some categorys from the csv file of my manufacturer. These excluded categorys must not be imported in my shop.

Is this possible with magmi?

My csv file from the manufacturer is realy big, with lotst of products and categories.

Hope you guys can help me out. I have already worked with magmi, but i was'nt be able to fix this one.

1
I'm not sure what you're trying to do but could you preprocess the csv file in excel to get what you want?PedroKTFC

1 Answers

0
votes

This is doable using the ValueReplacer plugin which has interesting mapping capabilities.

You can use the ValueRemapper Helper of this plugin to use a mapping file between your input csv value & the values that are to be ingested by magmi. It can also create a composite value from several input columns (here you may use it to create a "categories" column that would aggregate the several categories from your input file)

For excluding values to import, the Import Limiter plugin can do it too by selecting rows to exclude based on any column criteria.

A Last option would be to use magmi programmatic APIs:

  • Datapump API would let you create a script that will wrap magmi calls letting you perform any operation on input data (but this would also mean you'll have to read the input file)
  • Creating a dedicated ItemProcessor plugin that would do data transformation suiting your needs in its "processItemBeforeId" method.