2007 Apr 02 9:20 AM
data : chrqty(4) type c,
cnvQty(14) type c,
valqty type p decimals 3.
chrqty = '1234'.
valqty = chrqty.
concatenate chrqty(1) chrqty(4) into cnvqty.
write: / chrqty, "Character Qty,
/ cnvqty,
/ valqty round +3 . "Value Qty.
*Example : string .....'1234'
convert val.'1.234
data : chrqty(4) type c,
cnvQty(14) type c,
valqty type p decimals 3.
chrqty = '1234'.
valqty = chrqty.
concatenate chrqty(1) chrqty(4) into cnvqty.
write: / chrqty, "Character Qty,
/ cnvqty,
/ valqty round +3 . "Value Qty.
*Example : string .....'1234'
convert val.'1.234
2007 Apr 02 9:28 AM
Amit,
REPORT ztest MESSAGE-ID 00.
DATA: char_format(10) TYPE c VALUE '12,345.56'.
DATA: decimal_format(10) TYPE p DECIMALS 2.
REPLACE ALL OCCURRENCES OF ',' IN char_format WITH space.
CONDENSE char_format NO-GAPS.
decimal_format = char_format.
Don't forget to reward if it useful.
2007 Apr 02 9:29 AM
hI...
u need not do all that..
just do this:
PACK CHRQTY TO VALQTY.
WRITE VALQTY.
Ram..
2007 Apr 02 9:46 AM
hi amit,
try this
WRITE <charqty> to <another char qty> unit <qty unit>
reward points if helpful
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |