on 10-29-2008 11:36 AM
Hi All,
I am working on SAP Scripts.I have a Quantity field in my Script.
when we display the Script the ouput due to this quantity field is smething like 10.000
but i need to display only 10
and if the value is 10.100
then i need to display 10.100
please send your useful inputs.
Hi,
First write the value to a character string.
Then replace .000 with null. (if not found nothing happens)
For example;
data lv_qty type vbap-zmeng.
data char_qty(10).
lv_qty = '10.000'.
Move lv_qty TO char_qty.
Replace '.000' IN char_qty WITH ''.
CONDENSE char_qty.
write / char_qty. " output 10
lv_qty = '10.100'.
Move lv_qty TO char_qty.
Replace '.000' IN char_qty WITH ''.
CONDENSE char_qty.
write / char_qty. " output 10.100
Likewise you have to adapt this to your requirement, revert back if u have doubts.
Regards
Karthik D
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Karthik...........the problem is solved thank you.....I have marked the question as answered..........thanks for all of you for taking time to find the answer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi vidya,
ex: &EKPO-MENGE&(.0)
Refer this link
[SAPscript symbols|http://firstsapabap.googlepages.com/SAPscript5_sssymbl.pdf]
Regards,
Sravanthi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This message was moderated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Use the FM : ROUND...
Or use a statement SPLIT at '.' (dot)...
Regards
Shiva
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.