Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.4.0

Bug #5310 order by on getUsers() doesn't work properly
Submitted: 2005-09-06 13:35 UTC
From: jeroen at terena dot nl Assigned: lsmith
Status: Closed Package: LiveUser_Admin
PHP Version: 5.0.4 OS: Linux
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 7 - 5 = ?

 
 [2005-09-06 13:35 UTC] jeroen at terena dot nl
Description: ------------ Order by is ignored when listing the users from the perm container Test script: --------------- $params = array(); $params['orders'] = array('auth_user_id' => 'DESC'); $users = $lu_admin->perm->getUsers($params); FYI: The following bit inside findTables() seems to cause $oders to be reset: if (array_key_exists($field, $orders)) { $orders[$this->alias[$field]] = $orders[$field]; unset($orders[$field]); } When the table isn't aliased, it gets reset. Changing $order to an empty array() Expected result: ---------------- properly ordered array Actual result: -------------- default ordering

Comments

 [2005-09-06 13:41 UTC] lsmith
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better. http://cvs.php.net/diff.php/pear/LiveUser_Admin/Storage/SQL.php?r1=1.38&r2=1.39&ty=u