[drupal-devel] [bug] Can't apply database update_128

timothy bennett drupal-devel at drupal.org
Thu Mar 24 21:06:10 UTC 2005


Issue status update for http://drupal.org/node/19399

 Project:      Drupal
 Version:      cvs
 Component:    database system
 Category:     bug reports
 Priority:     normal
 Assigned to:  Anonymous
 Reported by:  timothy bennett
 Updated by:   timothy bennett
 Status:       by design

Agreed.  Mea culpa.
Based on your comments, I dug deeper into my term_node table and I
actually had several duplicate tid-nid pairs.  Not sure how that
happened...


timothy bennett



Previous comments:
------------------------------------------------------------------------

March 24, 2005 - 20:28 : timothy bennett

Commit# 14491 modifies the term_node table to make both tid and nid
primary keys. That is,
ALTER TABLE term_node ADD PRIMARY KEY (tid,nid);
However, I've got nodes (as referenced by nid) that have multiple
taxonomy terms associated with them (as reference by tid). As such, the
node_term table with have duplicate entries of nid, one for each term
(tid) that the node is associated with. I don't believe you can make a
column a primary key if the values are not unique can you?
(Ref: http://drupal.org/node/19275)
-- timothy


------------------------------------------------------------------------

March 24, 2005 - 20:36 : chx

It's a multiple column PRIMARY KEY and it will apply unless you have the
same nid-tid pair twice which shall not happen...


------------------------------------------------------------------------

March 24, 2005 - 20:43 : Goba

Not a bug.





More information about the drupal-devel mailing list