Skip to Content
author's profile photo Former Member
Former Member

How to remove comma, zero for field of type currency in alv output

Iam getting value like 2,007.00 for filed of type currency in alv output.

Expected is 2007 ( excluding comm and decimal part)

Can you help me out.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Dec 18, 2008 at 09:10 AM

    Hi

    Move your currency field to a CHARATCER field.

    Cheers

    Ravish

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 18, 2008 at 09:14 AM

    Hi Subramani,

    You can handle this issue with field catalog.

    You have fields like DATATYPE, INTTYPE etc. in field catalog, where you can change the data type for display and hence control the commo and zeros.

    Best Regards,

    Ram.

    Edited by: ram Kumar on Dec 18, 2008 10:15 AM

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 18, 2008 at 09:20 AM

    pass the reference table name and fieldname in the field cat

    ls_fieldcat-fieldname = 'ANSAL'

    ls_fieldcat-tablename = 'GT_TAB' "--->ur internal table

    ls_fieldcat-cfieldname = 'ANCUR' " this needs to be there

    ls_fieldcat-ctabname = 'GT_TAB' " this needs to be there

    ls_fieldcat-datatype = 'CURR' " this needs to be there

    make sure u have this adjustment in the fieldcat .

    here cfieldname in some structureus can be as reffieldname

    suppress the decimals .

    vijay.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.