Title: WP database errors
Last modified: November 18, 2026

---

# WP database errors

 *  Resolved [ac1643](https://wordpress.org/support/users/ac1643/)
 * (@ac1643)
 * [1 week, 2 days ago](https://wordpress.org/support/topic/wp-database-errors/)
 * Hi there, not sure if you can help with this one but thought I’d try. I’m getting
   the same shield error on some (not all) of my sites:
 * —–
 * **WordPress database error:** [Can’t create table `DB1`.`wp_icwp_wpsf_botsignal`(
   errno: 150 “Foreign key constraint is incorrectly formed”)]
 * then some details about the table, and then re the foreign key:
 * FOREIGN KEY (ip_ref) REFERENCES wp_icwp_wpsf_ips(id) ON DELETE CASCADE ON UPDATE
   CASCADE ) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_520_ci;
 * —–
 * I’m not sure yet when this started, it may have been when I changed up to WP 
   version 6.7.11 from 6.4, or changing a setting in the plugin revealed a problem
   that was potentially there all along.
 * Do you have any suggestions as to how to fix this, or how I may investigate it
   further?
 * Many thanks,
   Adam
    -  This topic was modified 1 week, 2 days ago by [ac1643](https://wordpress.org/support/users/ac1643/).
    -  This topic was modified 1 week, 2 days ago by [ac1643](https://wordpress.org/support/users/ac1643/).

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

 *  Plugin Author [Paul](https://wordpress.org/support/users/paultgoodchild/)
 * (@paultgoodchild)
 * [1 week, 2 days ago](https://wordpress.org/support/topic/wp-database-errors/#post-19076164)
 * It’s hard to know what exactly is happening here, but the most likely explanation
   is that your `wp_icwp_wpsf_ips` is probably of the “wrong” type (it’s MyISAM,
   not InnoDB), or it doesn’t exist.
 * If you’re familiar with MySQL, you could try dropping (deleting) all tables on
   your database whose name begins with `wp_icwp_wpsf_` – make sure to only select
   those tables, and **no other**.
 * This will reset a number of things on your Shield installation, but it’ll sort
   out your databases hopefully.
 * After doing this, you may see a number of errors in the PHP error log before 
   Shield “realizes” the tables are gone. You can ignore them.
 *  Thread Starter [ac1643](https://wordpress.org/support/users/ac1643/)
 * (@ac1643)
 * [1 week, 2 days ago](https://wordpress.org/support/topic/wp-database-errors/#post-19076417)
 * Hi Paul, your solution appears to have done the trick! I tried reinstalling the
   plugin, which I would have thought deletes and recreates the tables, but this
   didn’t work. I think its due database default character set conflicts, so I’ll
   keep investigating to try to ensure this doesn’t happen in the future.
 * Also just to say while I’m here that I much prefer the Shield UI in 22.4.0. I
   like:
    - The higher level config menus in one place along the top, and the vertical
      sub-menu down the left side. Much easier to navigate, saves a lot of scrolling
    - The quick-set light/medium/strong protection settings. I’ll still use my custom
      setup but its useful to see what is considered light and strong, and its a
      great time saving feature for those who don’t want to have to think about 
      every setting.
    - The setup guide is useful for newcomers and not instrusive
 * Its my favourite security plugin, keep up the great work 🙂

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

You must be [logged in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fwp-database-errors%2F%3Foutput_format%3Dmd&locale=en_US)
to reply to this topic.

 * ![](https://ps.w.org/wp-simple-firewall/assets/icon-256x256.png?rev=3054572)
 * [Shield Security – Smart Bot Blocking, Brute-Force Login Protection & File Scanning](https://wordpress.org/plugins/wp-simple-firewall/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-simple-firewall/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-simple-firewall/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-simple-firewall/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-simple-firewall/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-simple-firewall/reviews/)

## Tags

 * [Database Error](https://wordpress.org/support/topic-tag/database-error/)
 * [Shield Security](https://wordpress.org/support/topic-tag/shield-security/)

 * 2 replies
 * 2 participants
 * Last reply from: [ac1643](https://wordpress.org/support/users/ac1643/)
 * Last activity: [1 week, 2 days ago](https://wordpress.org/support/topic/wp-database-errors/#post-19076417)
 * Status: resolved