i- need to change relaeted products in upsell products . any suggestion how to do fast ? our shop have more than 35k products now we have create related products but we need to change in upsell

1 Answer 1


You can do this with a MYSQL script. However I would test the script below locally first and backup the relevant database tables beforehand. I have tested this on a vanilla install of Magento 1.9.2.

So the product relationship of related/upsell/crossell and also configurable products (they have a few more tables) are all stored in the database table "catalog_product_link".

They are distinguished between the 4 types in the column "link_type_id". So in order to switch related products to upsells, we just need to update this column for related products.

Note the id's of the different types are stored in "catalog_product_link_type" database table.

So this MYSQL script below will update all related products to upsells.

UPDATE catalog_product_link
SET link_type_id = 4
WHERE link_type_id = 1;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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