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

update column value

Former Member
0 Likes
453

hi experts

i have an internal table and i want to put a zero value in a certain field in all rows

how can i do that.

thanks

amit

3 REPLIES 3
Read only

Former Member
0 Likes
418

Hi

Try this

loop at itab.

itab-field1 = '0'.

itab-field2 = '0'.

modify itab transporting field1 field2.

endloop.

Regards

MD

Read only

Former Member
0 Likes
418

use

data : aindex like sy-tabix.

Loop at itab into wa_itab.

aindex = sy-tabix.

wa_itab-field1 = 0.

wa_itab-field2 = 0.

modify itab from wa_itab index aindex transporting field1 field2.

endloop.

Regards,

Alpesh

Read only

Former Member
0 Likes
418

Hi,

var1 = 0.

LOOP AT itab.

itab-fld2 = var1.

MODIFY itab.

ENDLOOP.

I hope the above coding will help you to solve your problem.

Regards,

Harish