Skip to content

Instantly share code, notes, and snippets.

@jb510
Created January 30, 2019 07:11
Show Gist options
  • Save jb510/0f49e427e421deddf1db0509fe7d2ca4 to your computer and use it in GitHub Desktop.
Save jb510/0f49e427e421deddf1db0509fe7d2ca4 to your computer and use it in GitHub Desktop.
MySQL Get WordPress Autoload data report
SELECT 'autoloaded data in KiB' as name, ROUND(SUM(LENGTH(option_value))/ 1024) as value FROM wp_options WHERE autoload='yes'
UNION
SELECT 'autoloaded data count', count(*) FROM wp_options WHERE autoload='yes'
UNION
(SELECT option_name, length(option_value) FROM wp_options WHERE autoload='yes' ORDER BY length(option_value) DESC LIMIT 25)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment