Jump to content

How to correctly change a product's main category in the database PS1.7.6.0?


Recommended Posts

Hi,
I’m trying to manually move a product to new categories and set a new main category directly in the database of PrestaShop 1.7.6.0. Here’s what I’ve done:

In the ps_category_product table:

Added new category assignments.

Removed old category assignments.

In the ps_product and ps_product_shop tables:

Updated the id_category_default field to the new main category.

Cleared the cache

Problem:

In BackOffice, the old category is still displayed as the main category, even though id_category_default points to the new category.

The product’s URL also does not update according to the new main category.

Are there any other places in the database I need to update to ensure the change in the main category and URL is correctly reflected in both BackOffice and the front end?

Thanks in advance for your help! 😊

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...