Update WordPress. Error_log: Tabelul wp_termmeta inexistent

By

Traian

Blog IT, MySQL, PHP, Wordpress

Cum se corecteaza eroarea lipsei tabelului wp_termmeta in WordPress

Din anumite motive, in urma unui update de WordPress tabelul wp_termmeta nu a fost creat (este o noutate incepand cu versiunea WordPress 4.4)

Site-ul functioneaza foarte lent din acest motiv.

Eroare in fisierul error_log:

[08-Feb-2016 15:19:23 UTC] WordPress database error Table 'wpdb.wp_termmeta' doesn't exist for query SELECT term_id, meta_key, meta_value FROM wp_termmeta WHERE term_id IN (1,28) ORDER BY meta_id ASC made by require('wp-blog-header.php'), require_once('wp-includes/template-loader.php'), include('/themes/mythemes/single.php'), get_header, locate_template, load_template, require_once('/themes/mythemes/header.php'), wp_nav_menu, wp_get_nav_menu_items, get_terms, update_termmeta_cache, update_meta_cache

Solutie: crearea tabelului wp_termmeta

Rulare query in phpmyadmin:

CREATE TABLE IF NOT EXISTS `wp_termmeta` (
`meta_id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`term_id` bigint(20) unsigned NOT NULL DEFAULT ‘0’,
`meta_key` varchar(255) DEFAULT NULL,
`meta_value` longtext,
PRIMARY KEY (`meta_id`),
KEY `term_id` (`term_id`),
KEY `meta_key` (`meta_key`(191))
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

Rezultat: eroarea eliminata

Site-ul functioneaza acum cu viteza de croaziera… ­čÖé

Etichete

 

Comments are closed.