Trying to add software channels to a kickstart profile results in a SQL syntax error with the PG-backend. Cause of the problem is Line 83 in ./java/code/src/com/redhat/rhn/domain/org/Org.hbm.xml in the Org.accessibleChannels query: <sql-query name="Org.accessibleChannels"> <![CDATA[SELECT {c.*} FROM rhnChannel {c}, rhnChannelCloned c_1_, rhnAvailableChannels cfp WHERE c.id = cfp.channel_id AND c.id = c_1_.original_id (+) AND cfp.org_id = :org_id]]> <return alias="c" class="com.redhat.rhn.domain.channel.Channel" /> </sql-query> The (+) syntax doesn't work with PostgreSQL. Kind regards, Julian
Reproduced with a fresh 1.4 install. Are there any workarounds?
Created attachment 498257 [details] Fixes the SQL query to work with PostgreSQL
I believe the attached patch fixes the query, at least it does for me.
Applied to spacewalk master as commit 645d46cbfc4c8fa217b90378b882357c887dae95 703143 - changed (+) to ANSI JOIN
There's still a typo in the commit (trailing comma after rhnChannel {c}), I attached a patch that fixes it.
Created attachment 499089 [details] Fixes SQL typo in commit 645d46cbfc4c8fa217b90378b882357c887dae95
I'm sorry for the typo. Thanks for the fix, it's commited as commit 1032f3b62a976446776da2223692cc750d6b0755 fixed SQL typo
This bugzilla is currently MODIFIED, so we believe the fix is in the Spacewalk nightly yum repository at http://spacewalk.redhat.com/yum/nightly/ Therefore, moving ON_QA.
Spacewalk 1.5 was released.
*** Bug 716592 has been marked as a duplicate of this bug. ***