Results 1 to 10 of 10
  1. #1
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default reset master categories ID?

    hi,

    is there a sql statement i can use to bulk reset master ID for multiple categories, im aware of the tool to do it one at a time however i use easy populate and am adding a minimum of 10-20 products a day from multiple categories.

    easy populate doesnt specify a master ID for the categories so i have to do each one individually. my categories rarely change so it would be a case of running the same statement each time that i would run quickly after adding new products.

    does anyone know if there is a quicker way of doing it other than the tool to do it individually please?

    any help very much appreciated :)

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: reset master categories ID?

    You could go to one of the Products in the Category you need reset and click C for Copy then the Multiple Categories Link Manager ...

    There is a setting for:
    Reset ALL Products in the selected Category to use the selected Category as the new Master Categories ID ...
    Example: Resetting Category 22 would set ALL Products in Category 22 to use Category 22 as the Master Category ID
    That would set all the Products in a specific Category to use that Category as its master_categories_id ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default Re: reset master categories ID?

    thanks ajeh, thats the way im doing it at the moment however each day after putting a number of products over a number of different categories and linking them etc etc - i have quite a few categories that need to be reset, i was wondering if there was a quicker way of resetting the master id for multiple categories at once??

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: reset master categories ID?

    Do you use Linked Products?
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  5. #5
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default Re: reset master categories ID?

    hello again ajeh thansk for replying, yes i do so i cannot use the store manager option to reset all either?

  6. #6
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: reset master categories ID?

    You can use it, but with Linked Products it is not the best way to do it as the master_categories_id is set based on the first categories_id found in the products_to_categories table and that is not always the correct one ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  7. #7
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default Re: reset master categories ID?

    sorry ajeh i think you may have misread my post :) i know that i cannot use that one as it wipes out my linked categories.

    i dont suppose there is an sql statement or an addon paid or unpaid which will allow me to reset multiple categories to be the master id?

  8. #8
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: reset master categories ID?

    Products have 1 master_categories_id ... the update in the Store Manager picks from the products_to_categories the first categories_id it finds on a search for the products_id in that database ...

    Unfortunately, that is not always the right categories_id to use, when Products are Linked Products ...

    I do not know of anything that makes a better choice, however I did write a test program that for large databases that turns off the indexes before getting the categories_id for a Product from the products_to_categories table so that the first record in the table is selected as that is often a "better" choice ...

    Post #29 of this thread:
    http://www.zen-cart.com/forum/showthread.php?t=188207

    has the updater test program that I made for Large databases that does this ...

    NOTE: be sure to backup your database before trying to use it ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  9. #9
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default Re: reset master categories ID?

    thanks ajeh, i did check that out however i think its complicating what i need a bit tbh. i just need a space where i can literally type

    96,97,98,99,100,101,105,106,108,109,110,111,115,121,122,186,194,204,206,211,222, 223,224,225,226,227,228,245,262

    to reset the categories at once or excecute an sql statement which loops through each category number :/

    its proving more difficult than i first thought :)

  10. #10
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: reset master categories ID?

    Afraid that there is nothing like that at this time ...

    You could always write something for that ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

 

 

Similar Threads

  1. v151 Implications of Master Category ID Reset on Linked Products
    By mexico in forum Setting Up Categories, Products, Attributes
    Replies: 9
    Last Post: 12 May 2016, 10:16 PM
  2. v139h I Need A MASTER at Master Categories please
    By traytray in forum General Questions
    Replies: 7
    Last Post: 13 Jul 2013, 11:31 PM
  3. Pressed Reset category master ID, now my products are deleted, not showing... DISAST
    By Argyle in forum Setting Up Categories, Products, Attributes
    Replies: 13
    Last Post: 2 Jan 2012, 05:58 AM
  4. How do I reset the master password?
    By oncloudnine in forum General Questions
    Replies: 1
    Last Post: 21 Jul 2010, 06:16 PM
  5. Master Category ID reset?
    By Tabby in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 22 Jan 2009, 06:40 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR