grabbed this query, It's a ton of help, but the group by statements are causing some issues... if I remove the group by, it works.
PHP Code:
SELECT node.iconid, node.prefixid, node.nodeid as nodeidsi, node.title as konubasligi, node.votes as begeeni, node.lastcontentauthor as uyeadi, node.lastauthorid as uyeidesi, node.routeid, node.lastcontent, node.created, node.lastcontentid, node.contenttypeid, node.parentid, node.textcount, node.totalcount as reply, icon.iconpath, icon.title as icontitle, closure.parent as forumidesi, closure.depth, forum.title as forumtitle, nodeview.count as viewsx, user.usergroupid, user.username, user.username, text.rawtext, text.previewimage
FROM node AS node
LEFT JOIN " . $TABLE_PREFIX . " closure AS closure ON (closure.child = node.nodeid)
LEFT JOIN " . $TABLE_PREFIX . "user AS user ON (user.userid = node.lastauthorid)
LEFT JOIN " . $TABLE_PREFIX . "icon AS icon ON (icon.iconid = node.iconid)
LEFT JOIN " . $TABLE_PREFIX . "nodeview AS nodeview ON (nodeview.nodeid = node.nodeid)
LEFT JOIN " . $TABLE_PREFIX . "node AS forum ON (forum.nodeid = closure.parent)
LEFT JOIN " . $TABLE_PREFIX . "text AS text ON (text.nodeid = closure.child)
LEFT JOIN " . $TABLE_PREFIX . "channel AS channel ON (channel.nodeid = closure.child)
LEFT JOIN " . $TABLE_PREFIX . "contenttype AS contenttype ON (contenttype.contenttypeid = node.contenttypeid)
WHERE node.parentid !=8 AND node.open !=0 AND closure.depth = 1 AND node.title !='' AND node.inlist = 1
GROUP BY node.title
ORDER BY node.created DESC
LIMIT 14
any thoughts on this ?
get this when I run With the group-by in.
failed : Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'DB_bb.node.iconid' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by