Instead of needing a tool like phpMyAdmin
or the mysql command line client to view and modify your WordPress database,
the SQL Executioner allows you to run arbitrary SQL queries against your
WordPress database from within the Admin. In many cases this allows you to bypass
the inherent limitations of the WordPress Admin interface, and use the full expressive
power of SQL to analyze and update your blog’s database.
To use simply install and visit the Tools > SQL Executioner page.
If you’re interested in contributing to the code behind this plugin, it’s also hosted on GitHub:
Extract the zip file, drop the sql-executioner folder in your wp-content/plugins/
directory, and then activate from the Plugins page.
- Does this plugin have any undo?
No. It executes SQL queries directly against your database. If in doubt, run a
query before attempting an
DELETEquery to confirm what
you are about to modify.
- Can I irreparably damage my WordPress database using this plugin?
- Do I have to know SQL to use this plugin?
Yes. Other than a basic facility that will
DESCRIBEeach table for you, there
is no GUI (graphical user interface).
- Added CSV export format (hat tip: olarmarius)
- Updated to work with PHP 7
- Cleaned code up to submit to WP Plugin Repo
- Wrapped functions in class
- Add wp_nonce_field check, minor code cleanup
- Initial version