Magento: Volume ID Store ID

I just imported ~ 800 products to Magento before I realized that I had store_id set to 0 when it was supposed to be 1.

Does anyone know an easy way to update this? I tried changing store_id to 1 in the spreadsheet and importing it again to update them, but it did not work.

I found this SQL at http://www.magentocommerce.com/boards/viewthread/1798/ , but I get syntax errors and unknown column errors, so I did not go further than that.

REPLACE INTO catalog_product_store (store_id, product_id) SELECT 1,entity_id from catalog_product_entity update catalog_category_entity set store_id = 1 where store_id = 0; update catalog_product_entity set store_id = 1 where store_id = 0; update catalog_product_entity_datetime set store_id = 1 where store_id = 0; update catalog_product_entity_decimal set store_id = 1 where store_id = 0; update catalog_product_entity_gallery set store_id = 1 where store_id = 0; update catalog_product_entity_int set store_id = 1 where store_id = 0; update catalog_product_entity_text set store_id = 1 where store_id = 0; update catalog_product_entity_tier_price set store_id = 1 where store_id = 0; update catalog_product_entity_varchar set store_id = 1 where store_id = 0; 
+4
source share
2 answers

Store ID 0 is the admin store - this is usually set when performing custom import operations. This is not a problem if you work with several stores.

The fastest way to update your products is to go to the "Catalog-> Product Management" menu, select all products and select "Update Status" and send. You can then assign the association of websites on the Websites tab in the menu that appears.

Mass processing of all products: Product Bulk Edit

To do this with code instead, you would want to browse your product collection and set up a website there or save an identifier. Example:

 $products = Mage::getModel('catalog/product')->getCollection(); foreach( $products as $product) { $product->setStoreId($storeId); try { $product->save(); } catch(Exception $e) { echo $e->getMessage(); } } 
+3
source

WOW .... This is a very best solution, because after 2 days I am working on a bug and decided a lot thanks

my problem:

I created a products csv file , I have 600 products, I all think that is good, in the admin panel it shows everything is fine, but on the product details page all products are not displayed

if I edit the product in the admin panel and just click the "Save" button without any changes, then it appears on the product details page,

since 2 days I'm worried about it,

I tried your best solution, after which I got it,

i selected all products

Actions โ†’ Update attributes โ†’ Send โ†’ select the Websites tab โ†’ Add product to the โ€œSitesโ€ field โ†’ mark โ€œMain siteโ€ โ†’ save.

what he...

ALL PRODUCTS ARE SHOWN IN THE PRODUCT DETAILS PAGE.

THANKS.

if anyone wants to want an example csv file, then please write to me, I will send a sample csv file, then your work will become easy ...

my mail id: kranthi@pixehub.com

0
source

Source: https://habr.com/ru/post/1387196/


All Articles