WordPress.org

Ready to get started?Download WordPress

Forums

Database tables (4 posts)

  1. Tamraica
    Member
    Posted 3 years ago #

    I am having some trouble with my database. The site seems to be functioning normally visually, but i am getting errors such as the following:

    made by require, require_once, do_action, call_user_func_array, xml_sitemaps->do_robots, xml_sitemaps->generate, sitemap_xml->generate, sitemap_xml->home
    [29-Dec-2010 19:54:22] WordPress database error Out of memory (Needed 8388580 bytes) for query
    SELECT posts.ID,
    posts.post_author,
    posts.post_name,
    posts.post_type,
    posts.post_status,
    posts.post_parent,
    posts.post_date,
    posts.post_modified,
    CAST(posts.post_modified AS DATE) as lastmod,
    CASE COUNT(DISTINCT CAST(revisions.post_date AS DATE))
    WHEN 0
    THEN
    0
    ELSE
    DATEDIFF(CAST(NOW() AS DATE), CAST(posts.post_date AS DATE))
    / COUNT(DISTINCT CAST(revisions.post_date AS DATE))
    END as changefreq,
    CASE
    WHEN posts.post_parent = 0 OR COALESCE(COUNT(DISTINCT children.ID), 0) <> 0
    THEN
    .4
    ELSE
    .8
    END as priority
    FROM wp_posts as posts
    LEFT JOIN wp_posts as revisions
    ON revisions.post_parent = posts.ID
    AND revisions.post_type = 'revision'
    AND DATEDIFF(CAST(revisions.post_date AS DATE), CAST(posts.post_date AS DATE)) > 2
    AND DATE_SUB(CAST(NOW() AS DATE), INTERVAL 1 YEAR) < CAST(revisions.post_date AS DATE)
    LEFT JOIN wp_posts as children
    ON children.post_parent = posts.ID
    AND children.post_type = 'page'
    AND children.post_status = 'publish'
    LEFT JOIN wp_postmeta as redirect_url
    ON redirect_url.post_id = posts.ID
    AND redirect_url.meta_key = '_redirect_url'
    LEFT JOIN wp_postmeta as widgets_exclude
    ON widgets_exclude.post_id = posts.ID
    AND widgets_exclude.meta_key = '_widgets_exclude'
    LEFT JOIN wp_postmeta as widgets_exception
    ON widgets_exception.post_id = posts.ID
    AND widgets_exception.meta_key = '_widgets_exception'
    WHERE posts.post_type = 'page'
    AND posts.post_status = 'publish'
    AND posts.post_password = ''
    AND redirect_url.post_id IS NULL
    AND ( widgets_exclude.post_id IS NULL OR widgets_exception.post_id IS NOT NULL )
    AND posts.ID <> 4

    GROUP BY posts.ID
    ORDER BY posts.post_parent, posts.ID
    made by require, require_once, do_action, call_user_func_array, xml_sitemaps->do_robots, xml_sitemaps->generate, sitemap_xml->generate, sitemap_xml->pages

    And when i look at the database in Phpmyadmin is says there are no tables in the database.

    Anyone know what's going on here? or have any sort of insight that might help me out?

    Thanks a ton, in advance.

  2. chrishajer
    Member
    Posted 3 years ago #

    Are you using this XML Sitemap plugin:
    http://wordpress.org/extend/plugins/xml-sitemaps/

    If so, I would disable it for now as it seems that the error is coming from that plugin.

    If disabling the plugin solves the problem, then I would contact the author of that plugin:
    http://profiles.wordpress.org/users/Denis-de-Bernardy/

  3. Tamraica
    Member
    Posted 3 years ago #

    I disabled the XML Sitemap plugin and i am still getting errors.

    The error is showing up like this now.

    [03-Jan-2011 15:44:57] WordPress database error Out of memory (Needed 2095112 bytes) for query SELECT DISTINCT post_id FROM wp_postmeta WHERE meta_key = '_footer-2' made by require, require_once, require_once, require_once, do_action, call_user_func_array, kws_gf_add_rewrite, WP_Rewrite->flush_rules, WP_Rewrite->wp_rewrite_rules, WP_Rewrite->rewrite_rules, do_action_ref_array, call_user_func_array, sem_nav_menu->flush_cache, delete_post_meta_by_key

  4. Tamraica
    Member
    Posted 3 years ago #

    Also when i check the database in phpMyAdmin the tables are not found. until i run a repair of the mySQL. but as soon as this error occurs again, the tables disappear again.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags