Title: WordPress database error Column &#8216;role&#8217; cannot be null &#8230;
Last modified: September 15, 2016

---

# WordPress database error Column ‘role’ cannot be null …

 *  Resolved [dlmerriam](https://wordpress.org/support/users/dlmerriam/)
 * (@dlmerriam)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/)
 * I was looking through my error.log for something else and saw this error. Any
   idea what it means? Sucuri shows my site as clean, but of course that doesn’t
   prove anything, just that it’s not something obvious.
 * WordPress database error Column ‘role’ cannot be null for query INSERT INTO `
   lp4_bpspro_login_security` (`status`, `user_id`, `username`, `public_name`, `
   email`, `role`, `human_time`, `login_time`, `lockout_time`, `failed_logins`, `
   ip_address`, `hostname`, `request_uri`) VALUES (‘Not Locked’, 19, ‘graciela8856’,‘
   graciela8856’, ‘gretchenhollway@spamavert.com’, NULL, ‘2016-09-14 17:56:17’, ‘
   1473893777’, ‘1473897377’, ‘1’, ‘107.150.80.149’, ‘107.150.80.149.dynamic.nationinternet.
   net’, ‘/wp-login.php’) made by wp_signon, wp_authenticate, apply_filters(‘authenticate’),
   call_user_func_array, bpspro_wp_authenticate_username_password

Viewing 8 replies - 1 through 8 (of 8 total)

 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8187811)
 * How old is this error? ie what is the date/timestamp? Are you seeing other errors
   of this same type? If this is just a one-time error then this is nothing to worry
   about and is not really worth trying to figure out. If these errors are occurring
   for every single login/failed login attempt then I have some ideas for why that
   is happening. So first let me know if this is just a “one-time” error and all
   other login handling/processing is ok.
 *  Thread Starter [dlmerriam](https://wordpress.org/support/users/dlmerriam/)
 * (@dlmerriam)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8188040)
 * It’s come up twice more today:
    [15-Sep-2016 18:00:59 UTC] WordPress database
   error Column ‘role’ cannot be null for query INSERT INTO `lp4_bpspro_login_security`(`
   status`, `user_id`, `username`, `public_name`, `email`, `role`, `human_time`,`
   login_time`, `lockout_time`, `failed_logins`, `ip_address`, `hostname`, `request_uri`)
   VALUES (‘Not Locked’, 19, ‘graciela8856’, ‘graciela8856’, ‘gretchenhollway@spamavert.
   com’, NULL, ‘2016-09-15 13:00:59’, ‘1473962459’, ‘1473966059’, ‘1’, ‘104.160.225.195’,‘
   104.160.225.195’, ‘/wp-login.php’) made by wp_signon, wp_authenticate, apply_filters(‘
   authenticate’), call_user_func_array, bpspro_wp_authenticate_username_password
 * and
 * [15-Sep-2016 18:52:14 UTC] WordPress database error Column ‘role’ cannot be null
   for query INSERT INTO `lp4_bpspro_login_security` (`status`, `user_id`, `username`,`
   public_name`, `email`, `role`, `human_time`, `login_time`, `lockout_time`, `failed_logins`,`
   ip_address`, `hostname`, `request_uri`) VALUES (‘Not Locked’, 19, ‘graciela8856’,‘
   graciela8856’, ‘gretchenhollway@spamavert.com’, NULL, ‘2016-09-15 13:52:14’, ‘
   1473965534’, ‘1473969134’, ‘1’, ‘104.160.228.38’, ‘104.160.228.38’, ‘/wp-login.
   php’) made by wp_signon, wp_authenticate, apply_filters(‘authenticate’), call_user_func_array,
   bpspro_wp_authenticate_username_password
 * I just noticed it for the first time yesterday. I’m keeping a closer eye on the
   error log file right now because of problems with updating a theme that I had
   on a couple hundred demo sites that was throwing errors on all of them.
 * But I’ve gotten two emails in the last two days sent (ostensibly) from my domain
   telling me to click to add “users” in emails that weren’t from anything I have
   installed. Needless to say, I didn’t click, but it made this error from BPS jump
   out at me.
 * I’ll continue to keep an eye on it.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8188184)
 * Ok so the errors are for the same user account. Is this a legitimate user account:
   graciela8856 on your website? When I google the users email address + spam this
   is a known spammer email address. Ironically spammers use spamavert to hide their
   real email addresses or just in general for spamming. This link: [https://cleantalk.org/blacklists/gretchenhollway@spamavert.com](https://cleantalk.org/blacklists/gretchenhollway@spamavert.com)
   was one of the google search results that were returned. So however this spammer
   is trying to authenticate to your site is triggering the error. If you are not
   seeing this error for any other legitimate user logins then you can just ignore
   the error.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8188207)
 * Oh left out one important detail, which is that 99% of all spamming and hacking
   is automated with bots. So probably when the spambot tries to auto-register or
   auto-login to your site then I assume the spambot script is fubar, which is then
   generating the error. 😉
 *  Thread Starter [dlmerriam](https://wordpress.org/support/users/dlmerriam/)
 * (@dlmerriam)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8188223)
 * No, this address is not anywhere legitimately in my site and there’s nothing 
   automated about registering. I have to approve them 🙂
 * So the script she (he, whatever) is external then, not a problem with my site
   or the plugin.
 * Great and thanks.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8188267)
 * Yep, this is an automated spambot login attack so nothing to worry about.
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8188274)
 * …since the spammers script is fubar and is probably either being blocked or just
   broken so it cannot hurt your site in any way.
    -  This reply was modified 9 years, 8 months ago by [AITpro](https://wordpress.org/support/users/aitpro/).
 *  Plugin Author [AITpro](https://wordpress.org/support/users/aitpro/)
 * (@aitpro)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8199806)
 * Assuming all questions have been answered – the thread has been resolved. If 
   the issue/problem is not resolved or you have additional questions about this
   specific thread topic then you can post them at any time. We still receive email
   notifications when threads have been resolved.

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘WordPress database error Column ‘role’ cannot be null …’ is closed to
new replies.

 * ![](https://ps.w.org/bulletproof-security/assets/icon-128x128.png?rev=1731938)
 * [BulletProof Security](https://wordpress.org/plugins/bulletproof-security/)
 * [Support Threads](https://wordpress.org/support/plugin/bulletproof-security/)
 * [Active Topics](https://wordpress.org/support/plugin/bulletproof-security/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/bulletproof-security/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/bulletproof-security/reviews/)

 * 8 replies
 * 2 participants
 * Last reply from: [AITpro](https://wordpress.org/support/users/aitpro/)
 * Last activity: [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-database-error-column-role-cannot-be-null/#post-8199806)
 * Status: resolved