Some products deleted from current database, can I get them back?

SubTitle: Deleting Category in 2.2.5 also deleted all products in that cat??

Hello … Right now I am still in a bit of shock but I will try to explain. I had many products in a specific sub-category and I made a new main category for these products. I added all those products (about 35) to the new main category, so now they were displaying in both the old sub-cat and the new main category.

This morning I decided to ‘end’ the old category so the products would not be double listed in the store. Strangely, simply deleting the old sub-category I just found out completes deletes ALL the products that were listed in that category … are you kidding me??? I mean even though they were listed in another category, they were still completely deleted…I searched the database, etc but they are gone. :cry:

I have a backup of my complete online store (including the databases) from about 1 month ago so the old database contains those wiped out products.

Is there any way of ‘importing’ just those missing products back into the store again?

Or taking a guess but can I upload that older database under a different name, and then using MySQL editor (phpMyAdmin) in CPANEL search out the deleted products then transfer them into the existing database? I am thinking this is probably the only way?

Is this really the only thing I can do to get those 35 deleted products back? I know I could manually type in all the products again, but then I do not remember the exact SEO URL’s from the products. Or is there another way that is time effient to reclaim those deleted products?

Thank you everyone!!

And anyone using 2.2.5, never simply delete old categories!!! Just make them ‘disabled’ or CS-Cart will make you pay dearly. :(

Quickest, easiest method…

1.Create a database backup within CS-Cart right now.

2. Restore the backup from 1 month ago.

3. Export the products within CS-Cart using Administration>Export > Products menu option, export every detail possible in the list of export items.

4. Restore the database created in step 1.

5. Import the product export files as created in step 3.

Unfortunately the deletion of Categories in CS-Cart is very poor. There should be a warning flagged to the user that deleting this category will delete all of the products in this category even if the product is also in another category. I get the logic, if a product is only in one category and you delete the category - to which category would the products be assigned to? None, because you may only have one category set up in the store. So the logic is correct there, but there should still be an option to delete a category and move the products to another category, or only delete the category and leave the products in the other category/categories only if the products exist in 2+ categories.

Thank you very much StellarBytes! :grin:

That process sounds much quicker and hunting out all the different products in the old tables and manually putting them in the current database tables.

Yes I completely agree … At least a popup stating ‘Deleting this category will REMOVE ALL PRODUCTS under this category’ would be nice. CS-Cart programmed in a warning on all the product type pages if you change anything but then try to leave that page without saving, it will popup and ask ‘Your changes have not been saved … Are you sure you want to leave this page?’. But nothing when it is about to wipe out a bunch of active products in your store?? Really???

Anyhow, thank you again!!!

That will really help. :)