views:

249

answers:

4

hello all I just want to ask ....

is there any method or tool by which csv/excel file of products can be directly imported to magento database?

I have no idea about it ..

Thanks! Richa

A: 

Yes there is, you can use it directly from the back-office. I know it imports CSV files, I am less sure about the Excel files but have a look.

greg0ire
+3  A: 

This depends heavily on what you want you want to import. Catalog products are generally supported (via CSV), but be careful about the data format or you'll end up with products that inexplicably don't show in the catalog. The best bet here is to create a product, export it from Magento as a CSV, and copy that format precisely.

For other objects (categories, for instance), Magento doesn't support import/export of data without some customization.

Also keep in mind that if you need to import a large number of products (many thousands), Magento's default import facility will run until the end of time before you finish importing.


If you have 2.6M products to get into the database, it will literally never finish if you use the framework. You need to write a script to parse your file and output straight SQL to get it into the database. You also need to plan seriously around the frontend performance issues you will be seeing with such a large Magento store.

On another note, you need to check that any solution you use is properly configured on a smaller batch of products before you let it run for dozens hours. If you complete the import before finding out that you failed to add to categories properly (for example), you're in for even more pain.

Also, I don't know about your particular use case, but large numbers of products like that can sometimes signal a flaw in the design. Make sure that you are leveraging product options properly and to maximum effect.

Joseph Mastey
with magento api we can set qty, price, manage stock and many more ..which is not defined in csv file ...hoe can we set them if we use this method
Richa
I agree with Joseph's point, do you **really** need 2.6M products or is there another way? managing that many products thru the admin will be fairly difficult, and it will have to adversely affect Magento's performance...
Jonathan Day
+2  A: 

Per @Joseph's answer, I recommend the following steps with some tips to help you:

  1. Create an example product in Catalog>Manage Products with all the custom attributes, images and data that you expect to replicate.
  2. Go to System>Import/Export>Profiles.
  3. Use the Export All Products profile to generate a CSV
  4. Edit the CSV using OpenOffice.org Calc (NOT Excel as it breaks CSV) to add all your files
  5. Copy your images into /media. The image paths in the CSV must start with "/" and be relative to the /media/ folder.
  6. Return to System>Import/Export>Profiles and run the Import All Products profile.
  7. Review the results of the import. You will need to repeat and tweak this process numerous times, it's very finicky, particularly regarding the image paths.

Also, one of the original Magento developers (now a freelancer) has an extension to perform large imports called RapidFlow. I haven't used it personally, but I have only heard positive reports, and his other code is excellent.

HTH, JD

Jonathan Day
do have any idea about time taken by it for 2,60,000+ products.. because currently m using magneto api to add products which taking half an hour for 500 products..that is so so much
Richa
well, as I said, I haven't used it myself, but his website claims the following stats: - Import 78,994 products with 120 attributes and 1,574 inline categories: ~33 minutes (39 rows/seccond)- Import 136,705 products with 974 attributes: ~67 minutes (34 rows/second)
Jonathan Day
If it does around 30 rows/sec (to be conservative), it will take just over 1 day of solid processing time to do the import into the database. It looks like that code may decrease in performance as number of categories or products increase? Worth a shot, perhaps.
Joseph Mastey
A: 

You don't need to export a product to figure out the CSV/Excel format.

Magento has Import/Export Profiles that can be created where the header (the first row of the CSV/Excel file) will be used to determine which attributes are being altered in the product.

If you go through the Default product attributes set (Catalog > Attributes > Manage Attributes), you can find out which product attributes are required to have a value and which ones are optional.

For example, to import some products with only a price, their name and a description, you would have the header of the file look like this: name | price | short_description

If you want to do anything fancy with multiple product image importing, you will have to resort to the API.

omouse