Last active
August 29, 2015 14:14
-
-
Save itsmikita/09a6a58268b56e2f0762 to your computer and use it in GitHub Desktop.
Changing WordPress database table prefix
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
After renaming table names: | |
1. | |
UPDATE {$new_prefix}options SET option_name = "{$new_prefix}user_roles" WHERE option_name = "{$old_prefix}user_roles"; | |
2. | |
UPDATE {$new_prefix}usermeta SET meta_key = "{$new_prefix}capabilities" WHERE meta_key = "{$old_prefix}capabilities"; | |
3. | |
UPDATE {$new_prefix}usermeta SET meta_key = "{$new_prefix}user_level" WHERE meta_key = "{$old_prefix}user_level"; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment