I really like what 'similar terms' is trying to achieve but I can't seem to get it working properly. I have a pretty fresh install of drupal 6.2. When I put the 'similar terms' block to the content area I get this warning:
user warning: Er is iets fout in de gebruikte syntax bij 'ROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE tn.tid IN (' in regel 2 query: SELECT n.nid, n.title, COUNT(n.nid) AS ncount ROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE tn.tid IN (21,13,18,10,12,16,14,11,9,8,15,17,22,19,20) AND n.nid != 4 AND n.status = 1 AND n.moderate = 0 GROUP BY n.nid, n.title, n.created ORDER BY ncount DESC, n.created DESC LIMIT 5 in /home/glowrich.com/www/sites/all/modules/similarterms/similarterms.module on line 154.
I haven't changed the code whatsoever.
Comments
Comment #1
Anonymous (not verified) commentedI have the same problem, but with the latest 5.x version. It all worked fine before I updated it this morning but now the blocks are no longer showing and I get error messages like this one:
user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE tn.tid IN (' at line 2 query: SELECT n.nid, n.title, COUNT(n.nid) AS ncount ROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE tn.tid IN (12,2) AND n.nid != 1309 AND n.status = 1 AND n.moderate = 0 GROUP BY n.nid, n.title, n.created ORDER BY ncount DESC, n.created DESC LIMIT 5 in /var/www/drupal/includes/database.mysql.inc on line 172.Comment #2
rmiddle commentedI am tiring to duplicate now. I wasn't seeing those issue in my test enviorment.
Comment #3
rmiddle commented6.x-1.3 Fixes the problem in 6. I still need to get 5 fixed.
Comment #4
rmiddle commentedNote if you select a group the error should go away.
Comment #5
rmiddle commentedOK 1.4 should fix this issue on both 5.x and 6.x.
Comment #6
Melle commentedrmiddle, thanks for the quick fix! Works like a charm now
Comment #7
Anonymous (not verified) commentedMelle - are you using 5.x or 6.x? I have installed the latest 5.x and even though I no longer get "user warning" the blocks simply do not show up at all...
Comment #8
Melle commentedI'm using 6.2.
Comment #9
rmiddle commentedTfR75,
It only shows up if you are looking at a node that has something to display. It wont show up on the main page or under views. It only shows up when you are looking at a node.
Comment #10
Anonymous (not verified) commentedI know (and am very happy that it works that way) - just that it does no longer show up on node pages.
Comment #11
rmiddle commentedT1R75 do you have a site I can look at? I am using the 5.x-1.4 on one site and it is working fine? Can you grab a screen shot of your config so I can see how you are setup and see if I can duplicate the issue?
Comment #12
Anonymous (not verified) commentedI am just looking into things. The problem is that some of the blocks are working on some pages and not on others. Blocks with a single vocabulary do usually seem to work fine - but I only use the one that has "Similar entries from ANY vocabulary." - that works on some pages and not on others, despite the others working fine. I will try and figure out whether there is a pattern. the site is www.arts-humanities.net
My configuration is:
Item count: 3
Content type limit: (none)
Users cannot control whether or not they see this block.
Visible for all roles
Show on every page except the listed pages. (none listed)
Comment #13
rmiddle commentedThe none is highlighted correct? I know that sounds like a dumb question but as I said I use the same on my 5 site same setup exactly and it seems to be working fine.
Thanks
Robert
Comment #14
Anonymous (not verified) commentedAddendum: it also seems to me that the module no longer chooses "similar" pages.
Example:
http://www.arts-humanities.net/node/help_questions_answers
This is a help page; it has only one tag "Digital Arts & Humanities". One would expect that similar pages are pages also tagged with that tag. However, that is not the case - similar gives various other pages (menu on the right hand side), *none* of which even have that tag. I have seen similar issues on other pages too.
Comment #15
rmiddle commentedDo you have a url to one that should be displaying but isn't that will likely help me the most in tiring to track down why?
Thanks
Robert
Comment #16
rmiddle commentedComment #17
Anonymous (not verified) commentedThe similar block is in the (grey) menu on the right hand side. You can see it on this page, for instance (or the above one):
http://www.arts-humanities.net/event/catac08_6th_international_conferenc...
It is not displayed on the following pages (for instance):
http://www.arts-humanities.net/event/call_for_papers_serious_games_on_th...
http://www.arts-humanities.net/escience/forum/escience_projects_meeting_...
http://www.arts-humanities.net/event/the_anthropology_of_youtube
And yes, the "none" in "Content Type Limit" is highlighted properly.
Thanks for your help, guys!
Comment #18
Anonymous (not verified) commentedAs it seems to work fine for you on 6.x-1.4 I changed it back to 5.x to make sure there is no confusion.
Comment #19
rmiddle commentedI have 2 sites with drupal 5 and 1 with drupal 6. Both seem to be working fine. check out middleswarth.net as that is my dump site. If you look at the bottom 3 items it shows how it is working fine with my tags.
Thanks
Robert
PS are you on IRC? I am robertlaptop in drupal-support.
Comment #20
rmiddle commentedTfR75,
I have just committed a possible fix to try. There will be a devel release in the next few hours with todays date see if that fix's your issue.
Thanks
Robert
Comment #21
Anonymous (not verified) commentedI have just installed the latest version and it runs smoothly on all pages (as far as tested, of course). Thank you very much for your work and the really fast response - that was great!
Comment #22
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.