﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
14513	Time for a wp_post_relationships table?	mikeschinkel		"Now that we have custom post types the obvious next step for people using them is to start relating post types using parent-child and/or many-to-many relationships.  I've implemented a taxonomy-mirrored-posts plugin but am starting to discover [http://lists.automattic.com/pipermail/wp-hackers/2010-July/033510.html many of the problems that @prettyboymp has pointed out on wp-hackers] and think it might be time we consider adding a new table to allow us to relate post and to allow us to build functionality around this table such as related post pickers, etc.

I'd like to offer a [http://en.wikipedia.org/wiki/Straw_man_proposal straw man proposal] to start discussions of a potential `wp_post_relationships` table added to WordPress 3.1 with three fields: `parent_id`, `post_id` and `term_taxonomy_id.` This allows us to relate any two post records and optionally associate at taxonomy+term to classify the relationship (here's the SQL to create the table): 

{{{
CREATE TABLE `wp_post_relationships` (
  `parent_id` bigint(20) unsigned NOT NULL,
  `post_id` bigint(20) unsigned NOT NULL,
  `term_taxonomy_id` bigint(20) unsigned NOT NULL DEFAULT '0',
  PRIMARY KEY (`parent_id`,`post_id`,`term_taxonomy_id`),
  KEY `term_taxonomy_id` (`term_taxonomy_id`),
  KEY `post_id` (`post_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
}}}

Looking forward to your feedback."	feature request	closed	normal		Post Types	3.0.1	normal	maybelater		mikeschinkel@… momo360modena ben@… sorich87@… mau wikichaves goto10 cogmios axwax johnnychen jwriteclub bainternet hello@… azizur ciobi deryk@… tammyhart trac@… frank@… mpretty@… chris@… dougal@… rwuensche@… sabreuse r_a_m_i@… chuck@… tomaugerdotcom@… freshman66 skippybosco sirzooro MHagemeister travis@… mercijavier@… info@… andrewayala jeremyfelt code@… lol@… murtrd ali.mohammadhosseini@… wordpress@… hhhsands marcosf wordpress@… wp@…
