
Originally Posted by
mcpisik
Hello! We have a few hundred empty spam accounts to delete.
All fields apart from name are empty, and cannot be deleted from admin.
So I need to delete them from the database 'customers' and 'customers_info' tables.
Is there any sql I coould insert, to delete a record where 'customers_email_address' = empty, for example.
(Sorry I don't know php)
We no longer get the spam accounts since upgrading, so would like to remove them now.
Thanks for any ideas.
if you can get access to phpmyadmin (or some other way to access the database), i would think the following would remove most if not all of what you want:
Code:
delete from customers where customers_email_address = '';
delete from customers_info where customers_info_id not in (select customers_id from customers);
delete from address_book where customers_id not in (select customers_id from customers);
backups are CRUCIAL prior to running sql commands. in addition if you have a prefix in your zen-cart tables, you would need to add that.
good luck and be careful!
no implied warranty for any SQL commands.
"to err is human... but to really mess things up you need a computer..... and to mess things up royally, you need SQL...."
william shakespeare
Bookmarks