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

MODIFY stmt is showing error.

Former Member
0 Likes
534

Hi Experts,

I have written MODIFY stmt in my code.

i have one internal table which is already having data. for specific field i want to fill up in that table.

so i got the data for that field from select single stmt..

ex:-

data: begin of itab occurs 0,

aubel type vbrk-aubel,

v_text(30),

end of itab.

loop at itab.

select single bstnk from vbak where vbeln = itab-aubel.

if sy-subrc = 0.

concatenate '/' bstnk into itab-v_text.

modify itab.

endif.

endloop.

when i am executing my program it is terminating the program.

can anybody help me.

Thanks & Regards,

venkat

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
516

Hi,

Try this.

Modify itab transporting v_text.

Use the above stmt for modifying.

Sharin.

Hi Experts,

I have written MODIFY stmt in my code.

i have one internal table which is already having data. for specific field i want to fill up in that table.

so i got the data for that field from select single stmt..

ex:-

data: begin of itab occurs 0,

aubel type vbrk-aubel,

v_text(30),

end of itab.

loop at itab.

select single bstnk from vbak where vbeln = itab-aubel.

if sy-subrc = 0.

concatenate '/' bstnk into itab-v_text.

modify itab.

endif.

endloop.

when i am executing my program it is terminating the program.

can anybody help me.

Thanks & Regards,

venkat

3 REPLIES 3
Read only

Former Member
0 Likes
516

Try:


MODIFY itab INDEX sy-tabix.

Also try not to do a select inside the loop. Pull all the data into a diff itab and then read the itab.

Read only

Former Member
0 Likes
517

Hi,

Try this.

Modify itab transporting v_text.

Use the above stmt for modifying.

Sharin.

Read only

Former Member
0 Likes
516

Hi,

Thanks for your reply.

Regards,

venkat