Application Development and Automation 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: 
Read only

reports

Former Member
0 Likes
766

Hi,

Data: begin of itab occurs o,

matnr type mara-matnr,

ersda type mara-ersda,

numb(2) type n,

end of itab.

for the first 2 fields i am retrieving data by making use of select query from mara

for the third field i did like this.

itab-numb = 12.

append itab.

do 50 times.

append itab.

enddo.

the problem is, suppose i retrieved some 50 rec from mara

then numb is displayed from 51 rec onwards instead cmng from 1 rec.

How to do it.

Regards,

siri

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
746

hi,

if u want itab-numb as 12 for all the recs then u use this,

i hope other 2 feilds u alreay appended in to itab.

loop at itab.

itab-numb = 12.

modify itab.

endloop.

then this works.

check it once

6 REPLIES 6
Read only

Former Member
0 Likes
746

Hi

Do like this, if alrady itab is having first 2 fields data.

<b>Loop at itab.

itab-numb = 12.

modify Itab index sy-tabix tranporting numb.

endloop.</b>

Reward points if useful

Regards

Anji

Read only

Former Member
0 Likes
746

hi

good

check your select statement,there must be some problem with your select statement,.

thanks

mrutyun^

Read only

Former Member
0 Likes
746

Please change ur logic ,

loop at itab.

itab-numb = what ever.

modify itab.

endloop.

regards

prabhu

reward if it is helpful

Read only

Former Member
0 Likes
747

hi,

if u want itab-numb as 12 for all the recs then u use this,

i hope other 2 feilds u alreay appended in to itab.

loop at itab.

itab-numb = 12.

modify itab.

endloop.

then this works.

check it once

Read only

0 Likes
746

HI,

if i want to give diff values to numb.

Regards,

siri

Read only

0 Likes
746

hi,

if u want to give diff values to numb also u need to write ur logic to get the numb value and then also use modify itab such that ,that numb value was maintained in ur internal table.