If you like to change the WordPress table prefix of the database on an existing WordPress website, you can use the following SQL query, where you have to update the header and the SET properties to your needs: database name oldprefix_ newprefix_ This is the SQL query: SET @database = “databasename”; SET @oldprefix = “oldprefix_”; … Continue reading “How to Change WordPress Table Prefix of mySQL Database”
Tag: mysql
Update procedures for Ubuntu Server, Nginx and MySql
These update procedures contain only essential information and best practices for updating a running ubuntu server and keeping the downtime low. Ubuntu 16.04.6 to Ubuntu 18.04 Backup – If you use a cloud hoster like digitalocean, create a snapshot. It’s recommended to power off the VM before creating the snapshot for keeping file integrity. If … Continue reading “Update procedures for Ubuntu Server, Nginx and MySql”
phpMyAdmin Repair and Optimize Database Tables Tutorial
Sometimes, it might be necessary to repair a MySQL database table. This can be the case if your WordPress site acts weirdly or slowly. So, for instance, when you notice that modified settings in your WordPress dashboard are not permanently saved, it could indicate a corrupted database table. Another indicator for a corrupted MySQL table … Continue reading “phpMyAdmin Repair and Optimize Database Tables Tutorial”
Change Language Collation of all mySQL Database Tables
If the language collation of your production and staging site database server is different you can use the MySQL query below to create a new query that allows you to change the language collation of all database tables at once. SELECT CONCAT(“ALTER TABLE “, TABLE_SCHEMA, ‘.’, TABLE_NAME,” COLLATE latin1_general_ci;”) AS ExecuteTheString FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA=”DATABASE_NAME” AND … Continue reading “Change Language Collation of all mySQL Database Tables”
MySQL Query: How to Delete all WooCommerce Orders
Use this MySQL query to delete all woocommerce orders at once from the MySQL command line. This can be useful if you want to delete all orders on your staging site and then import all orders again from the live site to make the staging site up to date before pushing it to the live … Continue reading “MySQL Query: How to Delete all WooCommerce Orders”