cancel
Showing results for 
Search instead for 
Did you mean: 

Conversion: TO_CHAR issue in SAP Infosteward

Former Member
0 Kudos

Hi All,

I've an issue in formatting a decimal type field with thousands & comma separator using 'to_char' in SAP Infosteward 4.2.

Here is the scenario:

Input: 12345.67

Desired output: 12,345.67

I've used the conversion as "to_char("12345.67", '9G999D.99') but I get the result as '345.67' instead of '12,345.67'.

Any help in resolving the issue is much appreciated.

Thanks,

Mani R

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

Hi Mani,

Your screenshot shows you are converting a decimal to a varchar but you are putting the results back into a decimal column. Try changing this so the result of the to_char() function is output to a varchar column. Thanks.

Doug

Former Member
0 Kudos

Awesome - Nice catch. Thanks Doug.

The issue is resolved now.

Answers (2)

Answers (2)

Former Member
0 Kudos

Doug,

Thanks for your reply. Unfortunately it's not working. I see <null> for values greater than 999.99. For instance value of '999.99' shows up correctly in the output view but value of '1000.11' shows up as <null>.

Here is my conversion statement

Thanks,

Mani. R

0 Kudos

Hi Mani,

Try the following:

to_char(12345.67, '99G,999D.99')

This works correctly for me and returns '12,345.67'


Regards,


Doug