NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
Packagist
Packagist, #3481 most downloaded on Packagist
A WPDB wrapper and query builder library.
Latest stable
1.3.1
Last release 1 months ago
19 Oct 2026
Release timing varies
gaps range from 3 weeks to 1.4 years
Nearly every release is documented
notes for 13 of 13 stable releases
Nothing withdrawn
no release was ever pulled
4 years old
13 releases · first in 2022
Drag across the ruler to compare, or tap a release to open it.
Version 1.0.8 doc updates by @lucatume in https://github.com/stellarwp/db/pull/20
Full Changelog: https://github.com/stellarwp/db/compare/1.3.0...1.3.1
null default are now explicitly nullable in DB::generate_results(), DB::generate_col() and DatabaseQueryException::__construct().wp-admin/includes/upgrade.php is now loaded only by DB::delta(), not before every query. On multisite, loading it on front-end requests also loaded wp-admin/includes/ms.php, which could cause a Cannot redeclare check_upload_size() fatal when another plugin or theme later required that file.DB::get_results(), DB::generate_results() and DB::generate_col() in the README.Your coding agent can read these notes before it upgrades. Set up the MCP server →
Feature: nested transactions by @defunctl in https://github.com/stellarwp/db/pull/26
Full Changelog: https://github.com/stellarwp/db/compare/1.2.0...1.3.0
beginTransaction() calls now create savepoints instead of issuing START TRANSACTION, which would implicitly commit any existing transaction.DB::transactionLevel() method to retrieve the current transaction nesting depth.DB::commit() releases the current savepoint when nested, and issues a real COMMIT only at the outermost level.DB::rollback() rolls back to the current savepoint when nested, and issues a real ROLLBACK only at the outermost level.tests-php.yml ensure slic runs in PHP 7.4.Refactor CRUD::delete method to support advanced DELETE queries by @shvlv in https://github.com/stellarwp/db/pull/25
CRUD::delete method to support advanced DELETE queries by @shvlv in https://github.com/stellarwp/db/pull/25Full Changelog: https://github.com/stellarwp/db/compare/1.1.1...1.2.0
Add Generator API methods by @lucatume in https://github.com/stellarwp/db/pull/17
Full Changelog: https://github.com/stellarwp/db/compare/1.1.0...1.1.1
DB::generate_results and DB::generate_col methods to the DB class to fetch all results matching an unbounded query with a set of bounded queries.Feature - Added upsert() method (props to @binarygary for the work!)
upsert() method (props to @binarygary for the work!)Tweak - Updates around trim() for php 8.1 compatibility.
trim() for php 8.1 compatibility.From() and Select() to convert passed non-strings to an empty string.Fix array shape for errors in DatabaseQueryException by @defunctl in https://github.com/stellarwp/db/pull/14
Full Changelog: https://github.com/stellarwp/db/compare/1.0.5...1.0.6
Tweak - Updating doc lock for whereExists() and whereNotExists() in response to a PHPStan flag.
whereExists() and whereNotExists() in response to a PHPStan flag.Tweak - Added more documentation for methods provided by DB.
DB.Tweak - Set composer.json config.platform.php to 7.0.
config.platform.php to 7.0.Fix - Adjust DB::insert(), DB::delete(), DB::update(), and DB::replace() signature to match wpdb's supported method signatures.
DB::insert(), DB::delete(), DB::update(), and DB::replace() signature to match wpdb's supported method signatures.DB::get_var(), DB::get_col(), and DB::get_results() signature of first arg to match wpdb's signature.Added a Config class to handle overrides of the DatabaseQueryException and addition of a hook prefix.
Config class to handle overrides of the DatabaseQueryException and addition of a hook prefix.ConfigConfig class to handle overrides of the DatabaseQueryException and addition of a hook prefix.Config## Added - Initial version - Documentation - Automated tests
One column per quarter.