Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

numeric field

naveen_inuganti2
Active Contributor
0 Kudos

Hi all....

Iam having one internal table with five fields and 10 records...

Now iam going to add one more record to that internal table in my program by using append statement...

itab-f1 = ' '.

itab-f2 = ' '.

itab-f3 = ' '.

itab-f4 = 'india '.

itab-f5 = ' '.

append itab.clear itab.

with above syntax i have to get four spaces and one entry....

but i am getting 0 for the last field, which is the numeric field...

how to avoid that zero...

there is no chanse to change numeric as char or others....because it is database table field using in some other reports and in other conditions in this reoprt also....

and

one more thing is iam dispalying this internal table by using table control, not with normal reporting!!!!

thank you,

naveen.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

while displaying or writing maintain as

no zero.

data : begin of itab occurs 0,

f1(10) type n,

f2(10) type n,

f3(10) type n,

f4(10) type c,

f5(10) type n,

end of itab.

data : india(10) type c.

parameters : i type i.

itab-f1 = ' '.

itab-f2 = ' '.

itab-f3 = ' '.

itab-f4 = 'india '.

itab-f5 = ' ' .

append itab.

write itab-f5 no-zero to india.

write india.

or if u want to display in table control then show india it will work,

with Regards,

Kiran.G

2 REPLIES 2

Former Member
0 Kudos

Hi,

while displaying or writing maintain as

no zero.

data : begin of itab occurs 0,

f1(10) type n,

f2(10) type n,

f3(10) type n,

f4(10) type c,

f5(10) type n,

end of itab.

data : india(10) type c.

parameters : i type i.

itab-f1 = ' '.

itab-f2 = ' '.

itab-f3 = ' '.

itab-f4 = 'india '.

itab-f5 = ' ' .

append itab.

write itab-f5 no-zero to india.

write india.

or if u want to display in table control then show india it will work,

with Regards,

Kiran.G

Former Member
0 Kudos

hi there....

yep, try this no zero concept in your code. it should work fine and ur trouble wil be over i guess....

regards.