SAP Development :: ABAP programming :: Field symbols ~ Runboard
SAP Development
 ABAP programming
  Field symbols
Support
Search
RSS

runboard.com       Sign up (learn about it) | Sign in (lost password?)


 
Umadevi
Registered user
Global user

Registered: 10-2006
Posts: 2
Karma: 0 (+0/-0)
Reply | Quote
Field symbols


Hi ,

Can anyone explain me about field symbols with some example.

Thanks.
10/26/2006, 6:19 am Send Email to Umadevi   Send PM to Umadevi
 
Vitaly Tarusin
Registered user
Global user

Registered: 11-2006
Posts: 5
Karma: 0 (+0/-0)
Reply | Quote
Re: Field symbols


Recently I've written small article about field-symbols in our local forum.

I can copy it here, but it's ON RUSSIAN emoticon

Do you need it?
11/29/2006, 10:55 am Send Email to Vitaly Tarusin   Send PM to Vitaly Tarusin
 
rucha
Registered user
Global user

Registered: 02-2007
Posts: 2
Karma: 0 (+0/-0)
Reply | Quote
Re: Field symbols


data: mem(7) type c value '12121'.
data: begin of gt_itab,
      a(5) type c,
      b(2) type c,
      end of gt_itab.

field-symbols <fs> like gt_itab.
assign mem to <fs> casting.
write:/ <fs>.


Field symbols allow you to access data objects dynamically in ABAP
programs. Field symbols are placeholders or symbolic names for other fields. They do not physically reserve space for a field, but point to its contents. A field symbol cam point to any data object.
The data object to which a field symbol points is assigned to it after it has been declared in the program.
Whenever you address a field symbol in a program, you are addressing the field that is assigned

so int the above code gt_itab is the data object. So this data object is assigned to FS.


2/9/2007, 11:58 am Send Email to rucha   Send PM to rucha
 


Add a reply






Link to us   -  Blogs   -  Hall of Honour   -  Chat
You are not logged in (login)      Board's time is: 11/28/2009, 7:20 am