[wp-trac] [WordPress Trac] #53958: Database: wp_postmeta - meta_key index

WordPress Trac noreply at wordpress.org
Thu Aug 19 09:38:58 UTC 2021


#53958: Database: wp_postmeta - meta_key index
--------------------------+-----------------------------
 Reporter:  wishe         |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Database      |    Version:  5.8
 Severity:  major         |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 The index on the **wp_postmeta** table for the meta_key column is set to
 **VARCHAR(191)**, While the column is **VARCHAR(255)**. This has a huge
 performance impact on queries that use the wp_postmeta table.

 In testing i noticed a performance increase on large websites with
 millions of records of several 100% when removing the index size on the
 column.

 This seems like a very obvious improvement and the issue has surely been
 raised before? So if there is a reason this cannot be altered without
 breaking something else I would like to know what that is.

 If you require any more information, let me know.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/53958>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list