I have loaded nmoderation module version (// $Id: nmoderation.module,v 1.8 2004/10/13 14:14:01 weitzman Exp $) and drupal 4.5rc.
i have the following error, when i navigate to http://mysite/?q=admin/nmoderation
<------------------------------------
user error: You have an error in your SQL syntax near 'ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' ' at line 1
query: SELECT COUNT(*) FROM nmoderation_uservotes nmuv JOIN nmoderation_votes v ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' JOIN users u ON nmuv.uid = u.uid WHERE n.status = 1 in database.mysql.inc on line 125.
user error: You have an error in your SQL syntax near 'ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' ' at line 1
query: SELECT v.vote, nmuv.value, nmuv.uvid, n.nid, n.title, nmuv.uid, u.name FROM nmoderation_uservotes nmuv JOIN nmoderation_votes v ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' JOIN users u ON nmuv.uid = u.uid WHERE n.status = 1 ORDER BY title ASC LIMIT 0, 50 in database.mysql.inc on line 125.
----------------------------------->
I entered values as,
(?q=admin/nmoderation/votes)
moderation votes : good
weight : 1
(?q=admin/nmoderation/roles)
then went to moderation roles:
i got automatically user role as
admin : 1 (editable field)
in moderation matrix:
(?q=admin/nmoderation/matrix)
the votes value is already present ie., good (in our example)
admin : 1 (editable field)
Now when i click on list (?q=admin/nmoderation)
i get those query errors again,
how to go about it.
And i am not sure if the above test values that i entered are right.
I would appreciate if someone can illustrate with an example. Which i am sure will support the documentation of this module later.
Database tables nmoderation_votes, nmoderation_roles) have values in it.
Still nmoderation_filters and nmoderation_uservotes has no values.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | nmoderation_joins.patch | 3.44 KB | grohk |
Comments
Comment #1
gkrishna commentedi didnt mention the database query error in the previous post, its here,
user error: You have an error in your SQL syntax near 'ON nmuv.mid = v.mid JOIN node n ON
nmuv.gid = n.nid AND nmuv.realm = 'node_nid' ' at line 1
query: SELECT COUNT(*) FROM nmoderation_uservotes nmuv JOIN nmoderation_votes v ON nmuv.mid
= v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' JOIN users u ON nmuv.uid
= u.uid WHERE n.status = 1 in database.mysql.inc on line 125.
user error: You have an error in your SQL syntax near 'ON nmuv.mid = v.mid JOIN node n ON
nmuv.gid = n.nid AND nmuv.realm = 'node_nid' ' at line 1
query: SELECT v.vote, nmuv.value, nmuv.uvid, n.nid, n.title, nmuv.uid, u.name FROM
nmoderation_uservotes nmuv JOIN nmoderation_votes v ON nmuv.mid = v.mid JOIN node n ON
nmuv.gid = n.nid AND nmuv.realm = 'node_nid' JOIN users u ON nmuv.uid = u.uid WHERE n.status
= 1 ORDER BY title ASC LIMIT 0, 50 in database.mysql.inc on line 125.
----------------------------->
Following in the cvs of mysql tables
http://cvs.drupal.org/viewcvs/*checkout*/contributions/modules/nmoderati...
its strange that nmoderation_filters table though created but never used in module here,
http://cvs.drupal.org/viewcvs/*checkout*/contributions/modules/nmoderati...
any thoughts/suggestions
Comment #2
gkrishna commentedupdate.....
Regarding configuration of nmoderation, i followed the steps as given for comment module.
http://drupal.org/book/print/286
though query error is still not fixed...
Comment #3
gkrishna commentedi have added keyword "INNER" (without quotes) before "join" in all the sql queries to fix the query error.
Comment #4
(not verified) commentedComment #5
grohk commentedThis bug seems to still be biting some people for some reason. I did some research and I reviewed this page:
http://drupal.org/node/2041
Does this patch that adds 'INNER' to the JOINS need to be applied to fix the problem?
Comment #6
jpwillms commentedI still have the same problem....
user error: You have an error in your SQL syntax near 'ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' ' at line 1
query: SELECT COUNT(*) FROM nmoderation_uservotes nmuv JOIN nmoderation_votes v ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' JOIN users u ON nmuv.uid = u.uid WHERE n.status = 1 in /home/httpd/vhosts/jordanwillms.com/httpdocs/drupal/includes/database.mysql.inc on line 66.
user error: You have an error in your SQL syntax near 'ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' ' at line 1
query: SELECT v.vote, nmuv.value, nmuv.uvid, n.nid, n.created, n.title, nmuv.uid, u.name FROM nmoderation_uservotes nmuv JOIN nmoderation_votes v ON nmuv.mid = v.mid JOIN node n ON nmuv.gid = n.nid AND nmuv.realm = 'node_nid' JOIN users u ON nmuv.uid = u.uid WHERE n.status = 1 ORDER BY created DESC LIMIT 0, 50 in /home/httpd/vhosts/jordanwillms.com/httpdocs/drupal/includes/database.mysql.inc on line 66.
Comment #7
grohk commentedjpwillms, you have not applied the patch that I have provided yet. Please do so and then post here if it does or does not correct your issue.
Comment #8
grohk commentedSetting to patch.
Comment #9
moshe weitzman commentedComment #10
(not verified) commented