WordPress.DB.DirectDatabaseQuery.SchemaChange

Schema Change

The plugin runs a direct database query instead of using a higher-level WordPress API or cache-aware pattern.

medium weight

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.

Affected Plugins

RankPluginScoreErrorsWarningsInstallsAddedUpdatedTop Issue
#551JoomSport – for Sports: Team & League, Football, Hockey & more255231,7471k+Direct Query
#552kk Star Ratings – Rate Post & Collect User Feedbacks257721,38870k+Non-prefixed global variable
#553Knit Pay – Cashfree, Instamojo, Razorpay, PayPal and more254,0191,2652k+Text Domain Mismatch
#554Local Pickup for WooCommerce255471,3891k+Non-prefixed global variable
#555Login Widget With Shortcode253351986k+wp function not compatible with requires wp
#556Loginizer258145041m+Output is not escaped
#557Logo Showcase – Responsive Logo Carousel, Logo Slider & Logo Grid256561,5065k+Non-prefixed global variable
#558Bulk Page Generator – LPagery256701,9263k+Non-prefixed global variable
#559M Chart255581,4653k+Non-prefixed global variable
#560Media Cleaner: Clean your WordPress!2515139190k+Direct Query
#561Media Cloud Sync251,0952741k+Exception output is not escaped
#562Minimum and Maximum Quantity for WooCommerce255561,4363k+Non-prefixed global variable
#563My Calendar – Accessible Event Manager25102,19320k+Non-prefixed function
#564All-in-one Sticky Floating Contact Form, Call, Click to Chat, and 50+ Social Icon Tabs – My Sticky Elements2535259740k+Non-prefixed global variable
#565Nexter Extension – Security, Performance, Code Snippets & Site Toolkit2519871210k+Nonce verification recommended
#566NOWPayments for WooCommerce – Crypto Payment Gateway255341,3064k+Non-prefixed global variable
#567Object Sync for Salesforce25192296500Non-prefixed global variable
#568Password Protected — Lock Entire Site, Pages, Posts, Categories, and Partial Content256811,513300k+Non-prefixed global variable
#569phpinfo() WP — Site Health, PHP Compatibility & Server Audit252767043k+Non-prefixed global variable
#570Plover Kit – Blocks, Patterns, Responsive Layout and Gutenberg Editor Enhancements256851,3823k+Non-prefixed global variable
#571Poll Maker by AYS – Versus Polls, Anonymous Polls, Image Polls254891,4137k+Non-prefixed global variable
#572Post Carousel Divi256861,3012k+Non-prefixed global variable
#573Post Snippets – Custom WordPress Code Snippets Customizer258081,65420k+Non-prefixed global variable
#574Premmerce257121,411500Non-prefixed global variable
#575Premmerce Redirect Manager257561,407500Non-prefixed global variable
#576Premmerce Product Search for WooCommerce255961,350900Non-prefixed global variable
#577Premmerce Wholesale Pricing for WooCommerce256351,377400Non-prefixed global variable
#578Quiz Maker by AYS255053,02320k+Non-prefixed global variable
#579Quttera ThreatSign – Web Malware Scanner for WordPress2533447110k+Non-prefixed global variable
#580Qyrr – simply and modern QR-Code creation255311,3122k+Non-prefixed global variable
#581Rate limiting for Contact Form 7255471,306500Non-prefixed global variable
#582Really Simple Featured Video – Featured Video Support for Posts, Pages & WooCommerce Products258111,4945k+Non-prefixed global variable
#583Restrict – membership, site, content and user access restrictions for WordPress255391,4012k+Non-prefixed global variable
#584The School Management – Education & Learning ERP2512,858800Non-prefixed global variable
#585Secure Copy Content Protection and Content Locking2595879920k+Output is not escaped
#586SEO Booster253931,4681k+Non-prefixed global variable
#587Seo Optimized Images255261,31610k+Non-prefixed global variable
#588SEO Repair Kit – Meta Manager, Schema Manager, SEO Content Monitoring, GSC Integration, Keyword & Rank Tracking251969022k+Direct Query
#589SimpLy Gallery255321,42240k+Non-prefixed global variable
#590Appointment Booking Calendar — Simply Schedule Appointments Booking Plugin2595873860k+Text Domain Mismatch
#591Simply Static – The Static Site Generator2516850130k+Non-prefixed hook name
#592Smart Image Resize for WooCommerce255824047k+Text Domain Mismatch
#593Smart Manager – Advanced WooCommerce Bulk Edit & Inventory Management2536692310k+SQL query is not prepared
#594Smart phone field for Gravity Forms255401,3166k+Non-prefixed global variable
#595Spice Blocks255361,3001k+Non-prefixed global variable
#596STAGGS – Product Configurator Toolkit256262,180400Non-prefixed global variable
#597Stylish Cost Calculator – Quote Generator, Lead Gen & Price Estimator256481,0211k+Output is not escaped
#598SupportCandy – AI Customer Support Ticket System & Live Chatbot Agent254321,35710k+Direct Query
#599Survey Maker by AYS255672,3976k+Non-prefixed global variable
#600TablePress – Tables in WordPress made easy258472,174600k+Non-prefixed global variable