Support » Plugin: Yoast SEO » Table wp_yoast_seo_meta needs primary key

  • Resolved drsdre


    Our managed MySQL 8.0 database has the option sql_require_primary_key set to on. This means every table should have a primary key. I think having this option switched on makes good sense as the primary key is the most efficient way for finding and updating table rows.

    In the original definition for wp_yoast_seo_meta there is no primary key, there is a unique index on object_id. This index has the same effect as setting the object_id as primary key.

    I would recommend to replace the unique index with primary key to make your plugin compatible with more MySQL setups.


Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support Jeroen Rotty


    Hi @drsdre,

    Thank you for reaching out and investigating.

    We would love it if you would take the time to create a feature request for our development team on our GitHub repository. You can do this over at Thank you.

    Thread Starter drsdre


    Plugin Support Jeroen Rotty


    Thank you @drsdre for creating it. Our development team picks up and checks new issues on GitHub regularly and they will respond there. Thanks.

    Plugin Support devnihil


    We are going ahead and marking this issue as resolved due to inactivity. If you require any further assistance please create a new issue.



    Hi, any updates about this improvement? I’m facing the same issue in Digital Ocean managed database.
    I’m getting several warnings about missing primary key in wp_yoast_seo_meta table.

    FYI, this is the warning

    Our systems have indicated that your MySQL cluster, db-mysql-xxx-xxxxx, has tables without primary keys. We have identified that MySQL tables without primary keys can lead to service replication issues that jeopardize performance and availability. If primary keys are not present for database tables exceeding 5,000 rows, data-loss can occur.

    This issue is going to get more pressing as Digital Ocean is now emailing daily if a table on their managed database doesn’t use a primary key.

    I think this issue needs reopening (closing an issue “due to inactivity” doesn’t “resolve” the issue… it just hides it under the carpet).

    We’re in the same boat here. Please take a look at this issue. Digital Ocean is pressing all sites to fix this ASAP.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Table wp_yoast_seo_meta needs primary key’ is closed to new replies.