2007 Aug 16 10:00 AM
hi Frnds,
I facing some problem in converting the currency .
The amount value is populated in a character object of length 15
for eg amt = 4,233.89
after uploading the value becomes 4.233.89
hence once while moving this value to a packed value with decimal 2 points , i am facing a dump since ther are decimal points at 2 places.
please help me in solving the issue.
regards,
Khushboo
2007 Aug 16 10:03 AM
You can use this code to change the decimals
This does not involve changing the user settings. This is dynamic and will not effect the user settings.
Hope this works, try it
select single * from USR01 where BNAME = SY-UNAME.
case USR01-DCPFM.
when 'X'.
translate L_AMT1 using ',.'.
translate L_AMT2 using ',.'.
when ' ' .
translate L_AMT1 using '.,'.
translate L_AMT2 using '.,'.
when others.
endcase.Regards
Gopi
hi Frnds,
I facing some problem in converting the currency .
The amount value is populated in a character object of length 15
for eg amt = 4,233.89
after uploading the value becomes 4.233.89
hence once while moving this value to a packed value with decimal 2 points , i am facing a dump since ther are decimal points at 2 places.
please help me in solving the issue.
regards,
Khushboo
2007 Aug 16 10:02 AM
Hi..
You can try this command to Move ur Char field to Pack field.
PACK <CHARFIELD> TO <PACK FIELD>.
<b>Reward if Helpful</b>
2007 Aug 16 10:13 AM
thanks for the reply but issue is that there are 2 points of decimal which are not correct . how to overcome this problem . 4,236.89 is converted to 4.236.89 which is a problem.
<b>reward will be given to the best answer</b>
2007 Aug 16 10:03 AM
You can use this code to change the decimals
This does not involve changing the user settings. This is dynamic and will not effect the user settings.
Hope this works, try it
select single * from USR01 where BNAME = SY-UNAME.
case USR01-DCPFM.
when 'X'.
translate L_AMT1 using ',.'.
translate L_AMT2 using ',.'.
when ' ' .
translate L_AMT1 using '.,'.
translate L_AMT2 using '.,'.
when others.
endcase.Regards
Gopi
2007 Aug 16 10:10 AM
Hi Tyagi,
Once Go for Menubar settings> user profile-> own data> Defaults.
check there for ur Decimal notation Might be here is the problem.
Try it once.
same problem i have faced but at tat time i do changes in type declaration i didnt remember exactly it might be(i,c)
Thanks
Naveen khan
Message was edited by:
Pattan Naveen
2007 Aug 16 10:14 AM
i need to do somethng genral cannnot change user's own data settings
2007 Aug 16 10:15 AM
2007 Aug 16 10:22 AM
2007 Aug 16 10:42 AM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |