web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
New commits:
commit 90c4713e476244a3cf83bff1244345b4bcb17b41
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Fri Feb 25 10:57:23 2011 +0100
Fixing systems_in_channel_family query for PostgreSQL.
Addressing
DBD::Pg::st execute failed: ERROR: for SELECT DISTINCT, ORDER BY expressions must
appear in select list\nLINE 11: ORDER BY UPPER(NVL(S.NAME, '(none)')), S.ID
diff --git a/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
b/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
index e261064..f482eee 100644
--- a/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
+++ b/web/modules/rhn/RHN/DB/DataSource/xml/System_queries.xml
@@ -873,6 +873,7 @@ ORDER BY SP.position
<mode name="systems_in_channel_family">
<query params="org_id, cfam_id, user_id">
+select * from (
SELECT distinct S.id, S.name
FROM rhnServer S,
rhnServerChannel SC,
@@ -882,7 +883,8 @@ SELECT distinct S.id, S.name
AND SC.channel_id = CFM.channel_id
AND CFM.channel_family_id = :cfam_id
AND EXISTS (SELECT 1 FROM rhnUserServerPerms USP WHERE USP.user_id = :user_id AND
USP.server_id = S.id)
-ORDER BY UPPER(NVL(S.NAME, '(none)')), S.ID
+) X
+ORDER BY UPPER(NVL(X.NAME, '(none)')), X.ID
</query>
<elaborator name="system_overview" />
<elaborator name="entitlements"/>
Show replies by date