Need to use the pristine column name without alias for sorting
authorJoey Schulze <joey@infodrom.org>
Thu, 12 Aug 2010 18:47:02 +0000 (20:47 +0200)
committerJoey Schulze <joey@infodrom.org>
Thu, 12 Aug 2010 18:47:02 +0000 (20:47 +0200)
lib/rico/dbClass2.php

index 94a3f13..0f6b8d9 100644 (file)
@@ -66,7 +66,7 @@ class sqlParse {
     if (!empty($this->WhereClause)) {
       $sqltext.=" WHERE ".$this->WhereClause;
     }
-    $sqltext.=" ORDER BY ".$this->UnparseColumn($colnum);
+    $sqltext.=" ORDER BY ".$this->arSelList[$colnum];
     return $sqltext;
   }