Title: Scary spammy database error
Last modified: December 18, 2020

---

# Scary spammy database error

 *  Resolved [Jim](https://wordpress.org/support/users/jwmc/)
 * (@jwmc)
 * [5 years, 5 months ago](https://wordpress.org/support/topic/scary-spammy-database-error/)
 * I had debugging log on the last few days. Today I was shocked to see a database
   error that involved a bunch of spammy phrases and icons. I don’t really know 
   what it means or where it came from. I searched the WF traffic log and found 
   no security entry that seemed to correspond at that time.
 * Can you tell how this happened? Is this something WF can block?
 * `[18-Dec-2020 17:00:52 UTC] WordPress database error Illegal mix of collations(
   utf8_general_ci,IMPLICIT) and (utf8mb4_unicode_ci,COERCIBLE) for operation 'like'
   for query SELECT SQL_CALC_FOUND_ROWS wp75_posts.ID FROM wp75_posts WHERE 1=1 
   AND wp75_posts.ID NOT IN (5729,5709,4178,2170,2433,1966,1908,1800,650,76) AND(((
   wp75_posts.post_title LIKE '%💕🦸 Pills without prescription on 🎁 www.xxxxxxx.
   store 🎁 Buy Levitra from $0.84/pill 🦸💕Purchase Levitra Canada - Levitra 20
   Mg Order Online%') OR (wp75_posts.post_excerpt LIKE '%💕🦸 Pills without prescription
   on 🎁 www.NetDoctor.store 🎁 Buy Levitra from $0.84/pill 🦸💕Purchase Levitra
   Canada - Levitra 20 Mg Order Online%') OR (wp75_posts.post_content LIKE '%💕🦸
   Pills without prescription on 🎁 www.xxxxx.store 🎁 Buy Levitra from $0.84/pill
   🦸💕Purchase Levitra Canada - Levitra 20 Mg Order Online%'))) AND (wp75_posts.
   post_password = '') AND wp75_posts.post_type IN ('post', 'page', 'attachment','
   ncpage', 'event') AND (wp75_posts.post_status = 'publish' OR wp75_posts.post_status
   = 'closed') ORDER BY (CASE WHEN wp75_posts.post_title LIKE '%💕🦸 Pills without
   prescription on 🎁 www.xxxx.store 🎁 Buy Levitra from $0.84/pill 🦸💕Purchase
   Levitra Canada - Levitra 20 Mg Order Online%' THEN 2 ELSE 6 END), wp75_posts.
   post_date DESC LIMIT 0, 15 made by require('wp-blog-header.php'), wp, WP->main,
   WP->query_posts, WP_Query->query, WP_Query->get_posts`
    -  This topic was modified 5 years, 5 months ago by [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/).
      Reason: x'd out domain, code block

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

 *  [asimiqbl007](https://wordpress.org/support/users/asimiqbl007/)
 * (@asimiqbl007)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/scary-spammy-database-error/#post-13813520)
 * I’m also having same error in log file .
 * WordPress database error Illegal mix of collations (utf8_general_ci,IMPLICIT)
   and (utf8mb4_unicode_ci,COERCIBLE) for operation ‘like’ for query SELECT SQL_CALC_FOUND_ROWS
   dbnameXXXXX_posts.ID FROM dbnameXXXXX_posts WHERE 1=1 AND (((dbnameXXXXX_posts
   WHERE 1=1 AND (((dbnameXXXXX_posts.post_title LIKE ‘%💕🦸 Pills without prescription
   on 🎁 [http://www.NetDoctor.store](http://www.NetDoctor.store) 🎁 Buy Levitra
   from $0.84/pill 🦸💕Purchase Levitra Canada – Levitra 20 Mg Order Online%’) OR(
 * anysolutions?
 *  Plugin Support [wfpeter](https://wordpress.org/support/users/wfpeter/)
 * (@wfpeter)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/scary-spammy-database-error/#post-13819421)
 * Hi [@jwmc](https://wordpress.org/support/users/jwmc/), thanks for dropping us
   a message regarding this.
 * That looks like it may be a bot just dumping spam in every text field it can 
   find, to see what kind of data can be submitted to your pages.
 * We assume fixing the collation of the posts table would clear this error. For
   the record, Wordfence doesn’t change database collations and observes the defaults
   currently set on your server when making changes or plugin updates. WordPress
   switched to using **utf8mb4** quite a while ago, so seeing that there’s a clash
   between some **utf8_general_ci** suggests it’s possible a WordPress update didn’t
   finish changing your tables back then, or perhaps a migration or restore from
   backup used the wrong collation so now you could have a mixture.
 * Ultimately, fixing the database collation is something to fix outside of Wordfence,
   but we do not believe this to be a compromise of your site.
 * Thanks,
 * Peter.
 *  Thread Starter [Jim](https://wordpress.org/support/users/jwmc/)
 * (@jwmc)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/scary-spammy-database-error/#post-13823746)
 * Thanks very much for that assessment. I’ll look into whether I need to dive in
   and address database character set and collation and how to do it. Seems very
   complicated and mysterious. The site works fine, so . . .
 *  Plugin Support [wfpeter](https://wordpress.org/support/users/wfpeter/)
 * (@wfpeter)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/scary-spammy-database-error/#post-13824261)
 * Hi [@jwmc](https://wordpress.org/support/users/jwmc/), thanks for coming back
   to me.
 * You can (and maybe already have) find some information on how to change collation/
   charsets in your chosen database with a web search, and in some cases your host
   may be able to give you some pointers.
 * Here’s a WordPress article highlighting the change and may assist in your understanding:
   [https://make.wordpress.org/core/2015/04/02/the-utf8mb4-upgrade/](https://make.wordpress.org/core/2015/04/02/the-utf8mb4-upgrade/)
 * Thanks,
 * Peter.

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

The topic ‘Scary spammy database error’ is closed to new replies.

 * ![](https://ps.w.org/wordfence/assets/icon.svg?rev=2070865)
 * [Wordfence Security - Firewall, Malware Scan, and Login Security](https://wordpress.org/plugins/wordfence/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordfence/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordfence/)
 * [Active Topics](https://wordpress.org/support/plugin/wordfence/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordfence/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordfence/reviews/)

## Tags

 * [sql injections](https://wordpress.org/support/topic-tag/sql-injections/)

 * 4 replies
 * 3 participants
 * Last reply from: [wfpeter](https://wordpress.org/support/users/wfpeter/)
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/scary-spammy-database-error/#post-13824261)
 * Status: resolved