• Resolved Wendihihihi

    (@wendihihihi)


    Hi Héctor,

    These error messages are filling my log file at the moment. The log goes back until June 19. I don’t know if they were there before as well. Any ideas how to fix this?

    Cheers

    [19-Jun-2022 09:53:03 UTC] Database error WordPress Table 'hellowthere.wp_popularpoststransients' doesn't exist for query SHOW FULL COLUMNS FROM *wp_popularpoststransients* called via require_once('wp-blog-header.php'), require_once('wp-includes/template-loader.php'), include('/themes/theme/single.php'), get_sidebar, locate_template, load_template, require_once('/themes/theme/sidebar.php'), dynamic_sidebar, WP_Widget->display_callback, WordPressPopularPosts\Widget\Widget->widget, WordPressPopularPosts\Widget\Widget->get_popular, WordPressPopularPosts\Cache::set
    
    [11-Jul-2022 12:36:08 UTC] Database error WordPress Table 'hellowthere.wp_popularpoststransients' doesn't exist for query SHOW FULL COLUMNS FROM *wp_popularpoststransients* called via require_once('wp-blog-header.php'), require_once('wp-includes/template-loader.php'), include('/themes/theme/404.php'), get_sidebar, locate_template, load_template, require_once('/themes/theme/sidebar.php'), dynamic_sidebar, WP_Widget->display_callback, WordPressPopularPosts\Widget\Widget->widget, WordPressPopularPosts\Widget\Widget->get_popular, WordPressPopularPosts\Widget\Widget->maybe_query, WordPressPopularPosts\Cache::set

    * = grave accent (otherwise it messes up the code formatting on WP forum)

    btw WP and plugin are all latest versions

    • This topic was modified 2 years, 4 months ago by Wendihihihi.
    • This topic was modified 2 years, 4 months ago by Wendihihihi.
    • This topic was modified 2 years, 4 months ago by Wendihihihi.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Hector Cabrera

    (@hcabrera)

    Hi @wendihihihi,

    Looks like you’re missing a database table for some reason, hence the error message.

    To force the plugin to recreate its database tables please add the following code to the wp-config.php file:

    define( 'WPP_DO_DB_TABLES', true );

    When you’re done, go to the Plugins screens, deactivate WordPress Popular Posts, then enable it again. The plugin should automatically create the missing table for you.

    Once you have confirmed that the table was created successfully (you can check via phpMyAdmin for example), remove the WPP_DO_DB_TABLES constant from your wp-config.php file.

    You can also create the table manually. To do so, log in into phpMyAdmin (or whatever your hosting provider uses to manage databases), select your site’s database, and run this query:

    CREATE TABLE wp_popularpoststransients (
      ID bigint(20) NOT NULL AUTO_INCREMENT,
      tkey varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL,
      tkey_date datetime NOT NULL,
      PRIMARY KEY (ID)
    ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

    (To anyone else reading this now or in the future you may need to change the wp_ prefix to whatever your site uses, see wp-config.php in the root of your public folder for more details).

    You may need to change the charset / collate information according to your own setup (but shouldn’t be necessary in most cases).

    • This reply was modified 2 years, 4 months ago by Hector Cabrera. Reason: Added info about the WPP_DO_DB_TABLES to recreate tables automatically
    Thread Starter Wendihihihi

    (@wendihihihi)

    You’re right, Héctor; it wasn’t there. I’ve added it and will see if that did the trick.

    Thank you for the fast reply.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘wp_popularpoststransients database error’ is closed to new replies.