mc12345678:
Sounds like this "move" process doesn't move the product to a new category so much as link it to the category. I say that because if it were truly moved, there should be no remnant/reference of the product to a previous category.
The table that contains the information I think you are trying to remove is the products_to_categories table.
Thinking:
delete from products_to_categories where products_id in (select products_id from products_to_categories where categories_id=15) and categories_id != 15;
>
> Where the categories_id of the "disabled" category is 15.
No the "move" moves the master_categories_id from where it is now to the specified category. Other linked categories remain the same.
Your code inspired me but would not work as written, had to create an alias before it worked :)
delete from products_to_categories
where products_id
in (select * from
(select products_id
from products_to_categories
where categories_id=15)
as old_table)
and categories_id != 15;
If run from phpmyadmin you need to add the table prefix to both instances of the table reference.
> **torvista:**
>
> I think this mod will do it:
> <http://www.zen-cart.com/showthread.php?180447-Multiple-Products-Copy-Move-Delete>
This is one of my favorite "must have" mods but unfortunately won't do what I need in this case
> **torvista:**
>
> and this has also some useful features along the same lines:
> <http://www.zen-cart.com/showthread.php?172698-Multiple-Categories-Link-Manager-Sorted>
>
> and yes I think they should both be added to the core!I have never tried this but will check it out.
Thanks to you both.