- Posts: 1
- Thank you received: 0
Change product_id in mysql
5 years 1 month ago #335713
by Imaginis
Change product_id in mysql was created by Imaginis
-- HikaShop version -- : 4.4.3
-- Joomla version -- : 3.9.21
-- PHP version -- : 7.2
Hello,
I need to recreate identically deleted products and reassign them the same product_id (so that a CRM can edit past stats...).
Can you confirm that I just need to modify the product_id in the hikashop_product and in the hikashop_product_category tables for a simple product without variants. Don't I forget other tables where the product_id is present?
Thanks in advance for your feedback.
-- Joomla version -- : 3.9.21
-- PHP version -- : 7.2
Hello,
I need to recreate identically deleted products and reassign them the same product_id (so that a CRM can edit past stats...).
Can you confirm that I just need to modify the product_id in the hikashop_product and in the hikashop_product_category tables for a simple product without variants. Don't I forget other tables where the product_id is present?
Thanks in advance for your feedback.
Please Log in or Create an account to join the conversation.
5 years 1 month ago #335719
by nicolas
Replied by nicolas on topic Change product_id in mysql
Hi,
You need to do this:
1 - create a new product and save it, without changing anything in it.
2 - change its id in both the hikashop_product and the hikahop_product_category tables
3 - then, you can add prices, images, options, etc via the interface
If you do step 3 before step 2, then you also need to update the product_id in the other tables, like hikashop_price where the prices are stored, or hikashop_file where the files and images are stored, etc. So it will get more complex and you might miss some entries.
You need to do this:
1 - create a new product and save it, without changing anything in it.
2 - change its id in both the hikashop_product and the hikahop_product_category tables
3 - then, you can add prices, images, options, etc via the interface
If you do step 3 before step 2, then you also need to update the product_id in the other tables, like hikashop_price where the prices are stored, or hikashop_file where the files and images are stored, etc. So it will get more complex and you might miss some entries.
Please Log in or Create an account to join the conversation.
Time to create page: 0.047 seconds