BI Publisher (MOSC)

MOSC Banner

dividing the sum of two value in each group in a number format using rtf

edited Feb 27, 2020 4:01AM in BI Publisher (MOSC) 1 commentAnswered

Hi,

I try to divide the sum of two value in each group and then I got the result. Now I want the result to in a number format '#,##0.00' but I got an error 'XML-22047: (Error) Invalid instantiation of 'xsl:when' in '_h' context.' How can I do that? Please see my code below, it's working if I remove the xdofx:format_number.

<?xdoxslt:set_variable($_XDOCTX, 'a', sum(current-group()/OR_AMOUNT))?>

<?xdoxslt:set_variable($_XDOCTX, 'b', sum(current-group()/WT_TOTAL))?>

<?xdofx:format_number(<?choose:?><?when: sum(current-group()/OR_AMOUNT)=0?>0<?end when?><?when: sum(current-group()/OR_AMOUNT)>0?>

Tagged:

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center