‎2007 Dec 10 12:07 PM
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,
‎2007 Dec 10 12:11 PM
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
‎2007 Dec 10 12:13 PM
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
‎2007 Dec 10 12:14 PM
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
‎2007 Dec 10 12:16 PM
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.
‎2007 Dec 10 12:18 PM
Hi,
You can use as below :
itab-field1 = '1234'.
append itab.What is the error u are getting?
Thanks,
Sriram Ponna.