cancel
Showing results for 
Search instead for 
Did you mean: 

Changing the output.

radhushankar
Participant
0 Kudos

Hi all

i working in a report i am getting output for a field like this <b>.4600</b> after some necessary calculations.

but while showing output i have to show it like this. .<b>46</b>.

can any one tel me how to change it.

Thanks in advance.

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member196280
Active Contributor
0 Kudos

I did not understand your question,Do you want to remove the zero's or you want to display only two decimal points....If you want to display 2 decimals do it like this in your report...

Ex,

DATA: amt(10) TYPE p DECIMALS 2.

Value = '0.4600'.

MOVE VALUE TO amt.

WRITE amt. "0.46 will be displayed....

Regards,

SaiRam

Former Member
0 Kudos

For standard reports, try:

REPORT ztest NO STANDARD PAGE HEADING LINE-SIZE 80 MESSAGE-ID 00.

DATA: amt(9) TYPE p DECIMALS 4.

amt = '46'.

WRITE: /001 amt,
       /001 amt DECIMALS 2.

Rob

Former Member
0 Kudos

Hi

Use the (.1) along with the field to display a single digit after decimal

(.2) means two digits after decimal, similarly like that .3, or .4 for 3 and 4 digits

so if you write &ITAB-MENGE(.2)& it display the field with 2 decimal palces only even if contains more digits after decimals

<b>Reward points for useful Answers</b>

Regards

Anji

Former Member
0 Kudos

&variable(.2)&