WARNING: TAKE A BACKUP OF YOUR PRODUCTION DATABASE BEFORE YOU DO THIS AND ALSO TRY THIS ON A DEVELOPMENT DATABASE FIRST!
If you know your ManufacturerID's then it shouldn't be too difficult:
Code:
DELETE FROM [ProductView] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductVector] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductStore] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductLocaleSetting] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductGenre] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductDistributor] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductCustomerLevel] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductAffiliate] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductSection] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductCategory] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductVariant] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [Product] WHERE [ProductID] IN (SELECT [ProductID] FROM [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3))
DELETE FROM [ProductManufacturer] WHERE [ProductManufacturer] WHERE [ManufacturerID] IN (1,2,3)
(1,2,3) represents the list of known ManufacturerIDs that you want to delete.
Other things to consider:
You might want to do this on the Kit tables aswell. And what about shopping cart tables? Do you really want to delete these products if they exist in either an order or a shopping cart? I wouldn't!
I've not tried/tested the scripts above, and there may be typo errors.