1

As the question says.

I want to import products, categories and custom attributes on database level. What tables do I need to take with me?

For the curious among you:

The reason is that I had a server that has been corrupted that used to host my website. Now all what I'm left with is a .sql file from a backup that contains all my products data. I also have an export of products from Magento admin in a .csv file. But I realized the hard way that Magento 2 default import/export is a total crap.

1

Magento 2:

Export Attribute tables:-

catalog_eav_attribute
eav_attribute_group
eav_attribute_label
eav_attribute_option
eav_attribute_option_swatch
eav_attribute_option_value
eav_attribute_set
eav_entity
eav_entity_attribute
eav_entity_datetime
eav_entity_decimal
eav_entity_int
eav_entity_store
eav_entity_text
eav_entity_type
eav_entity_varchar
eav_form_element
eav_form_fieldset
eav_form_fieldset_label
eav_form_type
eav_form_type_entity

Export Product tables:-

`cataloginventory_stock_item`
`cataloginventory_stock_status`
`cataloginventory_stock_status_idx`
`cataloginventory_stock_status_tmp`
`catalog_category_product`
`catalog_category_product_index`
`catalog_category_product_index_tmp`
`catalog_compare_item`
`catalog_product_bundle_option`
`catalog_product_bundle_option_value`
`catalog_product_bundle_price_index`
`catalog_product_bundle_selection`
`catalog_product_bundle_selection_price`
`catalog_product_bundle_stock_index`
`catalog_product_entity`
`catalog_product_entity_datetime`
`catalog_product_entity_decimal`
`catalog_product_entity_gallery`
`catalog_product_entity_int`
`catalog_product_entity_media_gallery`
`catalog_product_entity_media_gallery_value`
`catalog_product_entity_media_gallery_value_to_entity`
`catalog_product_entity_media_gallery_value_video`
`catalog_product_entity_text`
`catalog_product_entity_tier_price`
`catalog_product_entity_varchar`
`catalog_product_index_eav`
`catalog_product_index_eav_decimal`
`catalog_product_index_eav_decimal_idx`
`catalog_product_index_eav_decimal_tmp`
`catalog_product_index_eav_idx`
`catalog_product_index_eav_tmp`
`catalog_product_index_price`
`catalog_product_index_price_bundle_idx`
`catalog_product_index_price_bundle_opt_idx`
`catalog_product_index_price_bundle_opt_tmp`
`catalog_product_index_price_bundle_sel_idx`
`catalog_product_index_price_bundle_sel_tmp`
`catalog_product_index_price_bundle_tmp`
`catalog_product_index_price_cfg_opt_agr_idx`
`catalog_product_index_price_cfg_opt_agr_tmp`
`catalog_product_index_price_cfg_opt_idx`
`catalog_product_index_price_cfg_opt_tmp`
`catalog_product_index_price_downlod_idx`
`catalog_product_index_price_downlod_tmp`
`catalog_product_index_price_final_idx`
`catalog_product_index_price_final_tmp`
`catalog_product_index_price_idx`
`catalog_product_index_price_opt_agr_idx`
`catalog_product_index_price_opt_agr_tmp`
`catalog_product_index_price_opt_idx`
`catalog_product_index_price_opt_tmp`
`catalog_product_index_price_tmp`
`catalog_product_index_tier_price`
`catalog_product_index_website`
`catalog_product_link`
`catalog_product_link_attribute_decimal`
`catalog_product_link_attribute_int`
`catalog_product_link_attribute_varchar`
`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_relation`
`catalog_product_super_attribute`
`catalog_product_super_attribute_label`
`catalog_product_super_link`
`catalog_product_website`
`catalog_url_rewrite_product_category`
`downloadable_link`
`downloadable_link_price`
`downloadable_link_purchased`
`downloadable_link_purchased_item`
`downloadable_link_title`
`downloadable_sample`
`downloadable_sample_title`
`product_alert_price`
`product_alert_stock`

Export category tables:-

catalog_category_entity
catalog_category_entity_datetime
catalog_category_entity_decimal
catalog_category_entity_int
catalog_category_entity_text
catalog_category_entity_varchar
  • Thanks for the answer. Now I see that my products and categories are there. But whenever I go to the product page in admin, I receive the following error: pastebin.com/2SSwZadK – Hassan Al-Jeshi May 8 '18 at 10:27
  • Are you Importing Attribute using csv ? – Divyesh May 8 '18 at 10:30
  • No, I have imported the tables you have mentioned on a fresh Magento 2 install – Hassan Al-Jeshi May 8 '18 at 11:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.