WordPress.DB.DirectDatabaseQuery.DirectQuery

Direct Query

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
#2151Peter’s Post Notes362241023k+Output is not escaped
#2152Photonic Gallery & Lightbox for Flickr, SmugMug & Others3618011710k+Missing Translators Comment
#2153Photoswipe Masonry Gallery3657476k+Non Singular String Literal Text
#2154Plugins Garbage Collector (Database Cleanup)36325110k+Missing nonce verification
#2155Post Views Stats Counter36142241700Non-prefixed global variable
#2156ActiveCampaign Postmark for WordPress36477550k+Text Domain Mismatch
#2157WowStore – Store Builder & Product Blocks for WooCommerce36564374k+Non-prefixed global variable
#2158افزونه رسمی ترب36428620k+Exception output is not escaped
#2159Rara One Click Demo Import361229820k+Missing Translators Comment
#2160Better Find and Replace – AI-Powered Suggestions366712940k+Missing direct file access protection
#2161Recent Posts3610630500Text Domain Mismatch
#2162Optimize Database after Deleting Revisions3664412760k+Output is not escaped
#2163ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution3663667100k+Non-prefixed global variable
#2164SMTP for SendGrid – YaySMTP3627961k+Non-prefixed global variable
#2165StaticPress368879500Output is not escaped
#2166Subscribe to Comments3612916310k+Output is not escaped
#2167Supplier Order Email3654105400Output is not escaped
#2168SureContact – Newsletters, Email Marketing, Automation, Revenue Tracking & CRM363141326k+Text Domain Mismatch
#2169SurveyJS: Drag & Drop Form Builder3612134500Missing Version
#2170Sync QCloud COS3663109600Non-prefixed function
#2171Bulk Product Editor plugin allows you to create and edit your WooCommerce products and categories with Google Sheets.3650105400Direct Query
#2172Advance Side Cart, Ajax Cart & Floating Cart for WooCommerce36371216k+Non-prefixed global variable
#2173Plugin Name: Traffic Counter Widget Plugin3671107600Output is not escaped
#2174Zoho ZeptoMail36321105k+Request data is not unslashed
#2175FOMO & Social Proof Notifications by TrustPulse – Best WordPress FOMO Plugin361043910k+Output is not escaped
#2176Ubigeo de Perú para Woocommerce y WordPress361912354k+Non-prefixed function
#2177Uji Countdown36284984k+Text Domain Mismatch
#2178PDF Flipbook, WPBakery Addon – Unreal FlipBook36400921k+Non Singular String Literal Domain
#2179Virtual Classroom – Video Conferencing & Online Meeting with BigBlueButton3646138400Nonce verification recommended
#2180Video Thumbnails Reloaded36343582k+Text Domain Mismatch
#2181Quantity Plus Minus Button for WooCommerce36838410k+Output is not escaped
#2182Shipping with Venipak for WooCommerce36239611k+Text Domain Mismatch
#2183When Last Login365212350k+Non-prefixed global variable
#2184Widget Indicadores Económicos (Chile)365320500Output is not escaped
#2185Disable Payment Methods based on cart conditions for WooCommerce36158571k+Non Singular String Literal Domain
#2186Guaranteed Reviews Company (Société des Avis Garantis)363691971k+Output is not escaped
#2187Viva Payments – Viva Wallet WooCommerce Payment Gateway3697321k+Non Singular String Literal Domain
#2188Extended Coupon Features for WooCommerce FREE362196310k+Text Domain Mismatch
#2189Eway Payments for Woo36525403k+Text Domain Mismatch
#2190SuperFaktura WooCommerce36601162k+Nonce verification recommended
#2191Hide admin notices – Admin Notification Center36114678k+Output is not escaped
#2192WP Better Permalinks36110591k+Output is not escaped
#2193WP-Cleanup367929400Output is not escaped
#2194WP Coder – Insert & Manage Code Snippets365328010k+Nonce verification recommended
#2195WP Counter368643800Output is not escaped
#2196WP Custom Cursors | WordPress Cursor Plugin366913909k+Text Domain Mismatch
#2197WP-EMail36340951k+Unsafe printing function
#2198WP Header Images361741336k+Unsafe printing function
#2199WP Mail36202201500Output is not escaped
#2200WP Hardening (discontinued)362308510k+Text Domain Mismatch