Support » Plugin: Yoast SEO » [Crash/Query] WordPress-Datenbank-Fehler Unknown column ‘target_indexable_id’

  • Resolved strarsis


    Yoast SEO plugin seems to have issues with custom post type registration:

    NOTICE: PHP message: WordPress-Datenbank-Fehler Unknown column 'target_indexable_id' in 'where clause' für Abfrage SELECT COUNT(ID)
    FROM wp_posts
                    ID NOT IN (
       SELECT object_id
       FROM wp_yoast_indexable
               link_count IS NOT NULL
               AND object_type = 'post'
                    ID IN (
       SELECT DISTINCT post_id
       FROM wp_yoast_seo_links
               target_indexable_id IS NULL
               AND <code>type</code> = 'internal'
               AND target_post_id IS NOT NULL
               AND target_post_id != 0
            AND post_status = 'publish'
            AND post_type IN ('page', 'attachment', 'history_event', 'menu_page')
     von do_action('admin_init'), WP_Hook->do_action, WP_Hook->apply_filters, Yoast\WP\SEO\Integrations\Admin\Indexing_Notification_Integration->maybe_create_notification, Yoast\WP\SEO\Integrations\Admin\Indexing_Notification_Integration->should_show_notification, Yoast\WP\SEO\Helpers\Indexing_Helper->get_filtered_unindexed_count, Yoast\WP\SEO\Helpers\Indexing_Helper->get_unindexed_count, Yoast\WP\SEO\Actions\Indexing\Abstract_Link_Indexing_Action->get_total_unindexed

    Minimal PHP code to reproduce this issue:

    add_action('init', function() {
    	$args = array(
    		'public' => true,
    	register_post_type('history_event', $args);
    	$args = array(
    		'public' => true,
    	register_post_type('menu_page', $args);

    Two of these custom post types must be registered in order to cause the bug.
    The stripped down example code above would cause the same issue with labels and everything else added. It also doesn’t matter what custom post type slug is used.

    Thanks and
    with best regards

    • This topic was modified 1 month, 3 weeks ago by strarsis.
    • This topic was modified 1 month, 3 weeks ago by strarsis.
    • This topic was modified 1 month, 3 weeks ago by strarsis.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Suwash Kunwar



    We understand you’re getting database errors on your site when Yoast SEO Premium is activated. I imagine this can be frustrating. Let’s get to the bottom of it!

    First of all, can you please make sure you’re running the latest version of WordPress (5.6.1), Yoast SEO(15.8), and the latest version of your theme and ALL other plugins? Please also check if your server meets the minimum plugin requirements.

    If everything’s updated on your end and your server meets the minimum plugin requirements, we recommend resetting the Yoast indexables database tables by doing the following steps:
    1. Install & activate the Yoast Test Helper plugin
    2. Go to Tools > Yoast Test
    3. Hit the “Reset indexables & migrations” button.
    4. Go to SEO -> Tools and under “Optimize SEO Data” click the “Start SEO data optimization” button to rescan all your pages.

    Do the errors still appear?

    Thread Starter strarsis


    Yes, the re-index/-optimization fixed the issue. Though it is still technically a bug as this should have been done by the plugin after the update?

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.