how to use format mask in rtf template
Hi All,
How to use this code in rtf template?
SELECT TO_CHAR (TO_NUMBER (LINE_AMOUNT, 'FM9G999G999G999G990D99999'),'FM9G999G999G999G990D00000') AS formatted_value
FROM DUAL
Thank you,
try using XDOFX commands or XSLT samples below
<?xdofx:to_char('12345')?>
<?xdofx:to_number('12345')?>
<?format-number:fieldname;'999G999D99'?>
Hi Thank you,
YGUTTIKONDA wrote:try using XDOFX commands or XSLT samples below <?xdofx:to_char('12345')?><?xdofx:to_number('12345')?><?format-number:fieldname;'999G999D99'?>
How to use above code with SQL code ?
<LINE_AMOUNT>100<LINE_AMOUNT/> -->it is displaying 100.00000 if i use <?format-number:fieldname;'999G999D9999'?>
<LINE_AMOUNT>1,000.00<LINE_AMOUNT/> -->it is not displaying 1,000.00000 if i use <?format-number:fieldname;'999G999D9999'?>
I have PO Output for communication report and customized rtf template to see the PO Document output in PDF
Your second LINE_AMOUNT already has a formatting (like 9G999D99). The format-number tag is compartible only with plain numbers.
So if your xml would be like <LINE_AMOUNT>1000<LINE_AMOUNT/> the formatting should be used and therefore the output should also be correct.