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

Internal table field

Former Member
0 Likes
564

Hi

I have an ITAB. ITAB have a structure. Structure have multiple fields.

I want to populate some value to a field in that structure. How to represent that field?

EX:

itab-wa-field1 = '1234' . it is showing syntax error.

Can somebody help.

Urgent plz.

Points assured.

Cheers,

5 REPLIES 5
Read only

Former Member
0 Likes
550

Hi Buddy,

I think you are using internal table without header line thats why it is giving error. you can declare work area and do the assignmet of values to the fields.

Regards

Mukesh

Read only

Former Member
0 Likes
550

hi chinna,

first check your data type of field1. it may not be character.

and secondly check ur table is with header line or w/o headerline.

you may do like this for char field.

wa-field1 = value "like '1234'.

append wa to itab.

or give me your full prob. decsription so that i can help.

Regards,

Sachin Bhatnagar

Message was edited by:

Sachin Bhatnagar

Read only

former_member404244
Active Contributor
0 Likes
550

Hi,

use this statemnt

itab-field1 = '1234' ,if it has with header line

else

if it has declared without header line then u can use the below statement

loop at itab into wa.

wa-field1 = '1234'.

modify itab from wa transporting field1

endloop.

Reagrds,

nagaraj

Read only

Former Member
0 Likes
550

Hi,

Try in the following method

First declare the struture:

types:begin of is_abc

......

end of is_abc.

Declare internal table and workarea

Data:it_abc type is_abc with default key,

wa_abc type is_abc.

wa_abc-xyz = '123'.

append wa_abc to it_abc.

Reward points if found helpfull...

Cheers,

Chandra Sekhar.

Read only

Former Member
0 Likes
550

Hi,

You can use as below :

itab-field1 = '1234'.
append itab.

What is the error u are getting?

Thanks,

Sriram Ponna.