If this is your first visit, check our documentation. To post, register or login.
Forums / Configuring the Zen Cart Admin / Managing Customers and Orders / How to quickly get rid of 1000+ old customers from database?

How to quickly get rid of 1000+ old customers from database?

Started by heresy_miniatures on 15 Nov 2019, 11:25 AM · Views: 7,789

Results 1 to 3 of 3
15 Nov 2019, 11:25 AM
#1
heresy_miniatures avatar

heresy_miniatures

New Zenner

Join Date:
Jul 2011
Posts:
59
Plugin Contributions:
0

How to quickly get rid of 1000+ old customers from database?

Is there an sql code or something to allow me to quickly prune the old and no longer relevant customers from my database? I've got several thousand on there, going back to 2010, and what with gdpr, people moving house or changing email, efficiency and general jurisprudence and so forth I could probably do with deleting anyone who hasn't logged into their account in a few years as the data will be out of date anyway.

I can't believe that i will literally have to manually delete each and every account via the Admin - there must be a database query of some sort that I could apply? One that would delete people with, say, last log in before 2016 or no log in at all (blank entry)?

Any help appreciated!
ta
Andy

v 1.5.6

15 Nov 2019, 11:28 AM
#2
heresy_miniatures avatar

heresy_miniatures

New Zenner

Join Date:
Jul 2011
Posts:
59
Plugin Contributions:
0

Re: How to quickly get rid of 1000+ old customers from database?

Or indeed, based on their last order date...?

15 Nov 2019, 1:23 PM
#3
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,760
Plugin Contributions:
56

Re: How to quickly get rid of 1000+ old customers from database?

You may want to use my Delete Spam Customers mod, which can delete customers according to whatever query you want to build.

https://www.zen-cart.com/downloads.php?do=file&id=2253

That Software Guy. My Store: Zen Cart Support
Available for hire - See my ad in Services
Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
Do you benefit from Zen Cart? Then please support the project.