Relative Content

Tag Archive for mysqlwordpress

get_terms – unexpected result

I am creating a page with a list of terms of a custom taxonomy. Since there are a lot of them, I have split them into pages.

How to reduce my Sql database size of 2.6Gb

Have a Wordpress site, 40 pages, 10 posts, 20 videos. I did not notice my database swelled until I tried backing up, where every script (plugins) failed. One says “It has critical error”, other script simply hangs and says “error creating file”. Used a plugin DB Migrate, used the “Push” option to send all to my pc, it did, file size 270Mb. But when tried to “Pull”, it still connected to website, got 500 server error.
Not knowing what to do, I peeped inside the database, deleted 10593 entries of a “plugin” by issuing the command DELETE FROM aaaium_wpcs_gplcellar_items_cat_tbl, then it showed 0 entries. But while looking into Structure, those entries show up again, though when I click on left hand side entries, the same table now shows 0 entries.
Tried this too:
DELETE FROM wp_options WHERE option_name LIKE ‘transient%’;
It said something like invalid or no such entry
Have tried WP-Optimize and other such plugins, they do nothing but say it is “optimized”
Please guide me. Thanks

Can’t not import database to WordPress website

When I write command wp db import local.sql it returns Error: Failed to get current SQL modes. Reason: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
Note that I have pasted the local.sql to the C:UsersAdminLocal Siteswineapppublic

make table with plugin in wordpress

$departments_sql = “CREATE TABLE IF NOT EXISTS ‘” . $departments . “‘( ‘ID’ bigint(20) NOT NULL AND AUTO_INCREMENT, ‘name’ varchar(128) NOT NULL, ‘parent’ bigint(20) NOT NULL DEFAULT ‘0’, ‘position’ int(11) NOT NULL DEFAULT ‘1’, ‘description’ varchar(512) DEFAULT NULL, PRIMARY KEY (‘ID’), KEY ‘parent’ (‘parent’)) ENGINE=InnoDB” . $charset . “;”; make table with plugin in wordpress […]