hi folks,
I have two questions.
Here is the code.
select knumv kposn kschl krech kawrt kbetr kwert
from konv into table cdata for all entries in adinvoiceitab where konv~knumv = adinvoiceitab-knumv and
konv~kposn = adinvoiceitab-kposn.
loop at cdata into wac where knumv = wa-knumv.
case wac-kschl.
when 'ZRAT'.
if wac-kbetr = ' ' AND wac-kwert = ' '.
continue.
else.
p = p / 10.
if p < 1.
rate+0(1) = '-'.
endif.
i = p.
c = i.
shift c right deleting trailing '-'.
concatenate rate c '%' into rate.
condense rate no-gaps.
MOVE rate to w_accitab-zrate.
clear rate.
MOVE wac-kwert to w_accitab-zsubtotal.
endif.
Here I loop the data (numeric value) and convert it to character, concatenate % to the number.
My question is if the numeric value is 0 the internal table value should be blank because the value '0' is displaying in the form and I do not want that value.
How to do that?
Second question : From the query it is clearly evident that I am getting the records for various condition types from table KONV the important fields for me is 'kbetr' 'kschl' and 'kwert'.
For this Statement I only want records that have values in 'kbetr' and 'kwert' and how can i modify the query to get only these records and remove the other.
Thanks in advance.
Santhosh