ā2015 Apr 13 6:57 AM
Hello guys,
I have requirement like, need to sum a field called price in ALV grid. its type is dec(5,6). already maintained field catlog and checked fieldcatalog-do_sum = 'X'. Its working fine but problem is , if the field is 00.00 then i need to set as 'NA'.
Thanks in advance
ā2015 Apr 13 7:15 AM
Hi Sangeetha,
It is not possible for numeric/currency datatype. If required we can hide 00.00 value in the field, using field catalog attribute NO_ZERO = 'X'.
If the field data type is character/string, it is possible to rename 00.00 -> NA, but if you do like that do_sum won't work, summation should be done manually.
Regards
Rajkumar Narasimman
ā2015 Apr 13 7:20 AM
Hi Sangeetha,
Welcome to SCN...
It is not possible .
Why-
If make loop in final table if field value initial and fill 'NA' first it gives dump as compatibility problem
second if change amount field to char so we change value to 'NA' then it failed at the time of sum of field.
Hope this Will Help U
ā2015 Apr 13 7:29 AM
Thanks guys.
yeah i tried with these things, by changing dec to char, it didnt work.i dont want to make it manually, any how we have option called do_sum in field catlog. so its like, maintain 2 fields in output structure and one ref field for doing total sum calculation and other field for display purpose. is it possible in to make it ??
ā2015 Apr 13 8:24 AM
Hi Sangeetha,
Seems you can not do that. If you set that ref field as 'no_out', then it will not 'do_sum' action.
regards,
Archer
ā2015 Apr 13 8:30 AM
ā2015 Apr 15 7:44 AM
Hello,
i got the solution for this, i have used EDIT MASK in field catalog.
ls_fieldcat-edit_mask = '==ZRSCV'
ZRSCV is custom conversion exit name.
we can achieve by using this edit mask
if its helpful please reward the points.
Thanks