on 10-25-2012 9:40 AM
Dear All,
I used query and display some qty in this query. if i don't want to display the qty decimal place, anybody how to do it?
Regards,
Luke
Hi Luke,
define variable of type P for Quantity. e. g.
Data : ld_kwmeng type p.
ld_kwmeng = vbap-kwmeng.
you will get quanitty without decimal places.
Santosh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can use one of these mathematical functions to round your number up or down (CEIL, FLOOR), or to extract only the integer or fractional part (INT, FRAC)
http://help.sap.com/erp2005_ehp_04/helpdata/en/fc/eb3316358411d1829f0000e829fbfe/content.htm
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Luke,
Its simple logic.
Take the qty in a string and split it at decimal point. Use the first one.
example :
data: str1,str2,str3 type string.
str1 = qty.
split str1 at '.' into str2 str3.
write str2.
str2 will give you the value w'out decimal.
Regards...
Sultana
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
102 | |
12 | |
11 | |
6 | |
5 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.