Basically i tried to create a rule that limits the amount of published items per Group (using OG integration) and I got an SQL error saying:

User warning: Column 'nid' in field list is ambiguous query: SELECT nid FROM node INNER JOIN og_ancestry ON node.nid=og_ancestry.nid WHERE og_ancestry.group_nid = 123 AND node.type='philosophy' in _db_query() (line 128 of /home/matiasfigueroa/grey/grey-site-www/grey-dev/includes/database.mysql.inc).

this is easily solved modifying just one line of the code, the one with the query with the ambiguous column SELECT.

I've attached a patch with the fix for this, I've tested it on my environment and it worked just fine.

Regards

CommentFileSizeAuthor
node_limitnumber.patch735 bytesmx7102

Comments

held69’s picture

Confirming the patch is working.

Thanks!