Support » Plugin: Membership 2 » Deleted User Remains in DB locking up that email address

  • Resolved klogan2


    I’ve noticed that if I add a user with email address, then delete that user (which I’m doing a lot for testing), the user actually remains in the database, and I can’t use that email address to register with again, UNLESS of course I manually go into the DB and delete that record of the deleted user.
    I could see this becoming a problem over time, with people registering,, opting out for awhile, and then coming back to register again using the same email address (and possibly even the same User Name)
    Kevin Logan

Viewing 8 replies - 1 through 8 (of 8 total)
  • Updating this,, but getting confused. NOW (and I don’t know why) when I delete a User (member) via Dashboard/Users/All User/delete, the record IS being removed from the database.
    Trust me,, wasn’t hallucinating earlier today 🙂
    But I am trying to figure it out,,so the prob doesn’t occur again. I have changed some of my setting (access levels and such) in Membership,,, but I wasn’t really keeping track or checking the DB as I went along,,,
    so for now, problem solved 🙂

    this might be related,,and I do realize that this might not be a ‘Membership’ issue at all,, it could well be a WordPress or BuddyPress issue, but:
    Right now I have 2 users, both admins & NO subscribers, but if I go to dashboard/users/all users it’s showing a total of 3 users, including ONE subscriber,,, yet the 1 subscriber should NOT be there.
    As I say, this might not be a Membership issue,,but if anyone has any ideas I’d love to hear it/them.
    Cheers, Kevin

    UPDATE (again,,sorry people): I have found that indeed, Membership shows 1 user for the access level I registered a test user for, and also 1 user for the subscription plan I registered a test user for, even though I deleted the test user. Further, I went into the database m_membership_relationships and there was a record of a registration,,, I deleted that record (backed up of course) and NOW Membership shows no users on my access levels screen nor any users on my subscriptions screen.
    But, if I go to WP/Dashboard/User/All Users, it still shows 1 subscriber, which is inaccurate.
    Is this a potential problem, or am I worried about nothing???



    WPMU DEV Support Staff

    Hi @klogan2,

    Thanks for posting on all this. Could I ask though, if you simply create a new user then delete the user, does Membership then shown the correct number of users?

    I mean, without editing the database at all? Just wondering if maybe the database edit altered the standard functionality.

    Also, to clarify, when you delete a user, WordPress does still keep record of the email for a certain grace period. I don’t recall how long it’s for, but it does that automatically and isn’t normally a problem. You can indeed alter that default feature in the database as well.


    Hi David, sorry for delay,,, I was distracted by another job,, but I’m back on this now.
    Last I did,
    1) I have 2 existing admins users.
    2) I registered a user via Membership registration (form includes BuddyPress Extended Fields) – Worked fine
    3) I deleted that User
    4) Membership shows the 2 admins
    5) WP/Dashboard/Users/All Users shows: All (3) | Administrator (2) | Subscriber (1) | Pending (0) ,,,BUT, there are only 2 users displayed in All & Administrator (when clicked & displayed) & none in Subscriber when clicked on ,,, also now after the new user was deleted shouldn’t it be: All (2) | Administrator (2) | Subscriber (0) | Pending (0),,, I would say yes, that seems logical & would be accurate to the current ‘membership’ numbers.
    Note though, as far as I can tell,,, the Membership plugin is actually showing accurate info,, it’s showing the 2 admins, and no mention of the deleted user via dashboard/Membership/All Member,, including to view by filters (subscription & access levels). It’s only Dashboard/Users/All Users showing the inaccurate head count.
    To be honest, this makes me a bit nervous, indicating that possibly something is ‘off’ in the DB,,, and I really want to avoid the issue/head count causing a problem (perhaps unanticipated at this time) down the road,,after the site is being heavily used by the club (Running club in the UK)

    I’ve tried using the WP/Dashboard/Membership/Options/Repair Membership table stuff AND the WP/Dashboard/Tools/BuddyPress ‘Count Total Members’ And ‘Repair user last activity’ hoping that either of these would get everything back in sync.

    What I’m going to do today is set up some test email addresses, register with say 10 new users,, then delete them 1 at a time & see what happens.

    1) You mentioned WP has a ‘Grace Period’,,, do you know where that setting in the database is,,, I Googled some & all I get is deleting accounts stuff,, totally diff subject. I’d love to set that to (guessing) 0 or null or off or false,, whatever… Seems plausible to me that anything left over during this ‘grace period’ of a deleted member/user could be the source of the unSyncness (I love inventing new words)
    2) Actually had another question,, but it’s slipped my mind,, if it comes back,, I’ll edit here.


    Sorry man,, I may be driving y’all nutz,,, I just noticed on WP/Dashboard/Membership/Membership it shows this:
    Member counts
    Total Members 2
    Deactivated Members 1

    Could it be the deactivated member =1 causing the problem??? The ‘Total Members’=2 is presumably reflecting my 2 admins, who are ‘active’ in Membership, I don’t have any ‘Deactivated Members’ per se,, JUST at this point 1 ‘DELETED’ user,,, different statuses IMO



    WPMU DEV Support Staff

    Hi @klogan2,

    Really sorry for the delay here. Just to quickly check, are you by any chance able to see the correct number of users in ‘wp_users’ in your database?

    If you have older accounts still in that table, you could potentially delete them and that might sort this one out.

    But to be sure I understand as well, are the total users off both in Membership > Members as well as Users > All Users?

    Thanks for your patience with this, let’s get this sorted! 🙂


    Plugin Author WPMU DEV – Your WordPress Team


    WPMU DEV Support Staff

    Hi there Kevin,

    I hope you were able to get this sorted but if this is still any trouble, we’ll gladly assist if you’ll just let us know those further details. 🙂


Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Deleted User Remains in DB locking up that email address’ is closed to new replies.