I'm using indexpage to index a wiki-like system of terms. These terms are editable and revision history is tracked. That said, each time a node is edited, it appears an additional time in the indexpage table. For example, I just created an entry for 'Darren McGavin'. I edited it a few times to add some style. It now appears in the indexpage list 4 times. Each links to the exact same node.
I'm using Drupal 4.7.0-beta4.
I do not know the cause of the problem. If you need more detail, I can hopefully provide it.
Comments
Comment #1
coplan commentedHas anyone been able to duplicate this problem?
For reference, I include the following link(s) from my own site. Note that each one of the duplicate links points to the exact same place as its counterparts:
http://www.antisoc.net/indexpage/term/16
(Note, I am now using drupal 4.7.0-beta6 with the latest stable indexpage module)
Comment #2
Steve Dondley commentedI am not able to reproduce this with version 4.7. I'm using indexpage to list flexinode page.
Comment #3
patsas commentedI got the same problem using none flexinode page.
Here's a fix that solved the problem.
in the function indexpage_page_list add DISTINCT to the select statement:
Line 209: $sql = "SELECT DISTINCT r.title, n.nid, r.teaser FROM {node} n LEFT JOIN {term_node} t USING (nid) INNER JOIN {node_revisions} r USING (nid) WHERE type='%s' AND t.tid=%d";
Line 215: $sql = "SELECT DISTINCT r.title, n.nid, r.teaser FROM {node} n INNER JOIN {node_revisions} r USING (nid) WHERE n.type='%s' AND (r.title REGEXP '^[^[:alpha:]].*$')";
Line 219 $sql = "SELECT DISTINCT r.title, n.nid, r.teaser FROM {node} n INNER JOIN {node_revisions} r USING (nid) WHERE n.type='%s' AND (r.title LIKE '%s%%' OR r.title LIKE '%s%%')";
Comment #4
coplan commentedThat doesn't seem to solve the problem.
I just realized one thing that may be important. I'm using a nodetype that tracks revision history. It seems that the only nodes that appear in duplicate are nodes that I have revised a number of times. It seems to have an entry for each revision.
Comment #5
carlosparamio commentedI disabled "teaser in tooltip" functionality to fix this, because the problem was with the join to node_revisions. Anyway, that function was buggy, because it showed the content on the database, without filtering the text with the input format selected for the node.
Comment #6
nancydru@patsas: Actually if you change the USING to USING (nid, vid), this should go away.
If I get CVS access, this will be done. There will also be a setting to disable the teaser as a tooltip.
Comment #7
nancydruComment #8
nancydruComment #9
nancydru