Spacewalk 1.3 on postgresql.

When I click "virtualization" on page
/rhn/systems/details/Overview.do, it leads to:
/rhn/systems/details/virtualization/VirtualGuestsList.do
where this error is produced in catalina.out:

2011-04-03 20:07:31,442 [TP-Processor3] ERROR
com.redhat.rhn.common.db.datasource.CachedStatement - Error while
processing cached statement sql: SELECT
  DISTINCT VI.id,
           VI.host_system_id,
           VI.virtual_system_id,
           VI.uuid,
         NVL(VII.name, '(none)') AS NAME,
...
com.redhat.rhn.common.db.WrappedSQLException: ERROR: function
nvl(numeric, integer) does not exist

I figured out the query comes from
http://git.fedorahosted.org/git/?p=spacewalk.git;a=blob;f=java/code/src/com/redhat/rhn/common/db/datasource/xml/System_queries.xml;h=baa5bd3af264233adb2c7998aef6ab8a2adc149b;hb=SPACEWALK-1.3

Not just here but in general there are a lot of uses of the NVL() function which does not exist in postgresql.

The COALESCE() function is present in both oracle and
postgresql, and as far as I can tell, changing all occurrences
of nvl to coalesce will produce the same results.
Any chance that can be done across the board?

There are also uses of NVL2(), which is not directly portable to
COALESECE(), but eliminating NVL() might be a good first step though.

_______________________________________________
Spacewalk-devel mailing list
Spacewalk-devel@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-devel

Reply via email to