From 2341aefae4213c68c6d7f925680002382ae94a45 Mon Sep 17 00:00:00 2001 From: niekt0 Date: Mon, 20 Jun 2011 16:11:06 +0200 Subject: [PATCH] getUserSubmission_children fix2 --- wwwroot/backend/mysql/backend.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wwwroot/backend/mysql/backend.inc b/wwwroot/backend/mysql/backend.inc index 8b21936..55eafab 100644 --- a/wwwroot/backend/mysql/backend.inc +++ b/wwwroot/backend/mysql/backend.inc @@ -288,10 +288,10 @@ public static function GetUserSubmissionsChildren($user_id,$limit=23,$offset=0,$ // XXX orderby mysql escape - $q = "select n1.* from nodes as n1 join + $q = "select child.*, from nodes as child join (select node_id,node_creator from nodes where node_creator='$user_id') - as j2 on n1.node_parent=j2.node_id - join users as j3 on j3.user_id=n1.node_creator order by node_created + as j2 on child.node_parent=j2.node_id and child.node_creator <> '$user_id' + join users as j3 on j3.user_id=child.node_creator order by node_created desc $orderby LIMIT $offset,$limit"; // $q="select users.*,nodes.* from nodes -- 2.30.2