cancel
Showing results for 
Search instead for 
Did you mean: 

Set all urlkey to check "Use Default Value" in category

SOLVED
Highlighted

Set all urlkey to check "Use Default Value" in category

Hi,

 

All of our category tree "urlkey" "Use Default Value" accidentally unchecked when setup.

May I know is there any method to reset it? (i.e. all categories "urlkey" check "Use Default Value"?

 

Thanks in advance.

 

Regards,

kf

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: Set all urlkey to check "Use Default Value" in category

Hi @kf_luk 

You need to delete the entries from the catalog_category_entity_varchar table for the particular store for which you want to use default values from default store.

 

You can use the following query. In which you need to change your store_id for which you want to delete. 

DELETE FROM `catalog_category_entity_varchar` WHERE `store_id` = 2 and attribute_id in(select attribute_id from eav_attribute where attribute_code in ('url_key','url_path'))



For example:
BEFORE

Screenshot from 2020-04-05 08-05-21.pngScreenshot from 2020-04-05 08-04-25.png

AFTERScreenshot from 2020-04-05 08-08-29.pngScreenshot from 2020-04-05 08-08-07.png

Take the database table backup before execute any query for safe side, I will also suggest to try once for a single category first. 

I hope it will help you!

----
Problem solved? Click Accept as Solution!

View solution in original post

4 REPLIES 4
Highlighted

Re: Set all urlkey to check "Use Default Value" in category

Hi @kf_luk 

You need to delete the entries from the catalog_category_entity_varchar table for the particular store for which you want to use default values from default store.

 

You can use the following query. In which you need to change your store_id for which you want to delete. 

DELETE FROM `catalog_category_entity_varchar` WHERE `store_id` = 2 and attribute_id in(select attribute_id from eav_attribute where attribute_code in ('url_key','url_path'))



For example:
BEFORE

Screenshot from 2020-04-05 08-05-21.pngScreenshot from 2020-04-05 08-04-25.png

AFTERScreenshot from 2020-04-05 08-08-29.pngScreenshot from 2020-04-05 08-08-07.png

Take the database table backup before execute any query for safe side, I will also suggest to try once for a single category first. 

I hope it will help you!

----
Problem solved? Click Accept as Solution!

View solution in original post

Highlighted

Re: Set all urlkey to check "Use Default Value" in category

Hi @Vimal Kumar 

 

Thanks for detail explanation. Will try it out and get back to you the result.

Your me a lot to save time.

 

Regards,

kf

Highlighted

Re: Set all urlkey to check "Use Default Value" in category

Hi @Vimal Kumar,

 

It work like a charm.  You save my life. 

Thank you.

 

The day before I spend 5 hours to Tick those checkboxes but still a lot of untick box left.

Thanks again for your detail explaination.

 

Regards,

kf

 

Highlighted

Re: Set all urlkey to check "Use Default Value" in category

Hi @kf_luk 

 

Glad to hear that it works well for you 😊

----
Problem solved? Click Accept as Solution!