[wp-trac] [WordPress Trac] #10905: Do not allow duplicate (post_id, meta_key, meta_value) rows in meta tables

WordPress Trac wp-trac at lists.automattic.com
Fri Jan 1 17:28:13 UTC 2010


#10905: Do not allow duplicate (post_id, meta_key, meta_value) rows in meta tables
--------------------------+-------------------------------------------------
 Reporter:  scribu        |       Owner:  ryan          
     Type:  defect (bug)  |      Status:  new           
 Priority:  normal        |   Milestone:  Future Release
Component:  Database      |     Version:  2.9           
 Severity:  normal        |    Keywords:  has-patch     
--------------------------+-------------------------------------------------
Changes (by scribu):

  * keywords:  needs-patch => has-patch


Comment:

 Should add a check on update_metadata() too. This is how I think it should
 work:

 If by performing the update you end up with duplicates, delete the old
 value and return true.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/10905#comment:14>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list