Repository: cloudstack
Updated Branches:
  refs/heads/master a38b17fff -> 34111df02


dynamic-roles: remove unnecessary order by ID

On some MySQL server envs, this may cause a SQL statement error, though
I was unable to reproduce it. Since it's not needed, an order by 'sort_order'
is enough, we can safely remove it.

Signed-off-by: Rohit Yadav <[email protected]>


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/1770f3cb
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/1770f3cb
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/1770f3cb

Branch: refs/heads/master
Commit: 1770f3cb86f84128c40571330af55a7255fa49cc
Parents: b4ad38d
Author: Rohit Yadav <[email protected]>
Authored: Wed May 18 13:46:18 2016 +0530
Committer: Rohit Yadav <[email protected]>
Committed: Wed May 18 13:46:18 2016 +0530

----------------------------------------------------------------------
 .../src/org/apache/cloudstack/acl/dao/RolePermissionsDaoImpl.java   | 1 -
 1 file changed, 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1770f3cb/engine/schema/src/org/apache/cloudstack/acl/dao/RolePermissionsDaoImpl.java
----------------------------------------------------------------------
diff --git 
a/engine/schema/src/org/apache/cloudstack/acl/dao/RolePermissionsDaoImpl.java 
b/engine/schema/src/org/apache/cloudstack/acl/dao/RolePermissionsDaoImpl.java
index 960b652..8f6fa83 100644
--- 
a/engine/schema/src/org/apache/cloudstack/acl/dao/RolePermissionsDaoImpl.java
+++ 
b/engine/schema/src/org/apache/cloudstack/acl/dao/RolePermissionsDaoImpl.java
@@ -156,7 +156,6 @@ public class RolePermissionsDaoImpl extends 
GenericDaoBase<RolePermissionVO, Lon
             sc.setParameters("roleId", roleId);
         }
         final Filter searchBySorted = new Filter(RolePermissionVO.class, 
"sortOrder", true, null, null);
-        searchBySorted.addOrderBy(RolePermissionVO.class, "id", true);
         final List<RolePermissionVO> rolePermissionList = listBy(sc, 
searchBySorted);
         if (rolePermissionList == null) {
             return Collections.emptyList();

Reply via email to