WordPress.DB.DirectDatabaseQuery.NoCaching
No Caching
The plugin runs a direct database query instead of using a higher-level WordPress API or cache-aware pattern.
Why It Shows Up
Plugin Check found `$wpdb` access that queries the database directly, changes schema, or bypasses normal caching expectations.
Why It Matters
Direct queries can be correct, but they are easier to make unsafe, slower at scale, and harder for WordPress to cache or filter.
How to Fix
- Use WordPress APIs such as post, term, metadata, option, or user functions when they fit the task.
- If direct SQL is necessary, prepare dynamic values and add a clear caching strategy for repeated reads.
- Keep schema changes in activation or upgrade routines and make them idempotent.
References
Affected Plugins
| Rank | Plugin | Score | Errors | Warnings | Installs | Added | Updated | Top Issue |
|---|---|---|---|---|---|---|---|---|
| #3201 | Posts List | 77 | 11 | 15 | 7k+ | Non-prefixed hook name | ||
| #3202 | SureRank SEO – Smart Assistant with Meta Tags, Social Preview, XML Sitemap, and Schema | 77 | 58 | 95 | 300k+ | Non-prefixed hook name | ||
| #3203 | Table Of Contents Block | 77 | 15 | 8 | 10k+ | wp function not compatible with requires wp | ||
| #3204 | Tagembed Social Feeds Widget | 77 | 21 | 137 | 10k+ | Non-prefixed function | ||
| #3205 | Taggbox – Free Social Media Widgets, Review Badges & Shoppable UGC | 77 | 23 | 113 | 1k+ | Direct Query | ||
| #3206 | Unattach | 77 | 4 | 11 | 900 | Nonce verification recommended | ||
| #3207 | Username | 77 | 5 | 8 | 800 | Deprecated function: screen_icon | ||
| #3208 | WP Comment Notification | 77 | 28 | 10 | 400 | Missing Arg Domain | ||
| #3209 | X-Currency – The Ultimate WooCommerce currency switcher for a smoother shopping experience | 77 | 17 | 77 | 1k+ | Non-prefixed global variable | ||
| #3210 | Claspo – Popups, Spin the Wheel & Email Capture | 78 | 107 | 16 | 1k+ | wp function not compatible with requires wp | ||
| #3211 | Web3 Crypto Payments by DePay for WooCommerce | 78 | 6 | 101 | 1k+ | Direct Query | ||
| #3212 | Image Alt Text | 78 | 5 | 19 | 9k+ | Nonce verification recommended | ||
| #3213 | Recent Posts | 78 | 7 | 2 | 400 | Database parameter is not escaped | ||
| #3214 | RSS Includes Pages | 78 | 4 | 8 | 10k+ | Output is not escaped | ||
| #3215 | WooCommerce Square | 78 | 6 | 266 | 80k+ | Non-prefixed hook name | ||
| #3216 | Auto Featured Image (Auto Post Thumbnail) | 79 | 5 | 30 | 50k+ | Non-prefixed hook name | ||
| #3217 | Boxzilla – WordPress Popup Builder | 79 | 4 | 64 | 20k+ | Non-prefixed global variable | ||
| #3218 | Klaviyo | 79 | 26 | 86 | 100k+ | Non-prefixed function | ||
| #3219 | Location Weather – WordPress Weather Forecast, Air Quality & Weather Widget | 79 | 567 | 10k+ | Non-prefixed global variable | |||
| #3220 | Real Category Management: Content Management in Category Folders | 79 | 4 | 73 | 2k+ | Non-prefixed constant | ||
| #3221 | Notifima – WooCommerce Stock Manager, Inventory Management, Waitlist | 79 | 121 | 42 | 3k+ | Text Domain Mismatch | ||
| #3222 | WP Last Modified Info | 79 | 45 | 32 | 40k+ | Short PHP open tag found | ||
| #3223 | WP Referral Code | 79 | 18 | 19 | 600 | Missing direct file access protection | ||
| #3224 | Antispam Bee | 80 | 4 | 38 | 700k+ | Nonce verification recommended | ||
| #3225 | ShopEngine Gutenberg WooCommerce Builder Blocks Addon – All in One WooCommerce Solution | 80 | 424 | 735 | 3k+ | Non-prefixed global variable | ||
| #3226 | Eli's PHP Compatibility Scanner | 80 | 1 | 22 | 400 | Missing nonce verification | ||
| #3227 | Flipbox | 80 | 14 | 17 | 2k+ | wp function not compatible with requires wp | ||
| #3228 | Pro Mime Types – Manage file media types | 80 | 55 | 98 | 2k+ | Non-prefixed global variable | ||
| #3229 | Random Content | 80 | 10 | 8 | 3k+ | Output is not escaped | ||
| #3230 | SureMail – SMTP and Email Logs Plugin with Amazon SES, Postmark, and Other Providers | 80 | 45 | 65 | 200k+ | Non-prefixed hook name | ||
| #3231 | Product Feed PRO for WooCommerce by AdTribes – Product Feeds for WooCommerce | 80 | 9 | 450 | 80k+ | Non-prefixed hook name | ||
| #3232 | GoCardless for WooCommerce | 80 | 60 | 1k+ | Non-prefixed class | |||
| #3233 | Discounts Per Payment Method on WooCommerce | 80 | 8 | 8 | 1k+ | Missing Translators Comment | ||
| #3234 | WP Social Ninja – Embed Social Feeds, User Reviews & Chat Widgets | 80 | 26 | 18 | 30k+ | Missing direct file access protection | ||
| #3235 | Change Permalink Helper | 81 | 5 | 5 | 900 | Direct Query | ||
| #3236 | Countdown Block | 81 | 14 | 10 | 4k+ | wp function not compatible with requires wp | ||
| #3237 | Joinchat – Enhanced "click to chat" | 81 | 17 | 32 | 700k+ | wp function not compatible with requires wp | ||
| #3238 | eCommerce Shipping Dashboard by UPS for WooCommerce | 81 | 6 | 35 | 1k+ | Non-prefixed constant | ||
| #3239 | LoftLoader | 81 | 17 | 19 | 70k+ | Missing direct file access protection | ||
| #3240 | OG — Better Share on Social Media | 81 | 14 | 51 | 30k+ | Non-prefixed hook name | ||
| #3241 | Price Table Block | 81 | 15 | 16 | 900 | file system operations mkdir | ||
| #3242 | Progress Bars | 81 | 15 | 14 | 500 | file system operations mkdir | ||
| #3243 | Orphans | 81 | 1 | 43 | 50k+ | Dynamic hook name | ||
| #3244 | Stream | 81 | 5 | 80 | 80k+ | Direct Query | ||
| #3245 | Team Member Block | 81 | 15 | 14 | 1k+ | file system operations mkdir | ||
| #3246 | Toggle Content | 81 | 16 | 12 | 700 | file system operations mkdir | ||
| #3247 | Typing Text | 81 | 15 | 16 | 600 | file system operations mkdir | ||
| #3248 | VS Event List | 81 | 1 | 259 | 8k+ | Non-prefixed global variable | ||
| #3249 | ShipStation for WooCommerce | 81 | 34 | 40k+ | Non-prefixed class | |||
| #3250 | Accordion Toggle | 82 | 17 | 11 | 2k+ | Non-prefixed class |