03-31-2008 11:58 AM
03-31-2008 12:02 PM
Hi Pradeep .
Field symbols .
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.
chk here.
http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3860358411d1829f0000e829fbfe/content.htm
&----
*& Chapter 24: Using Field Symbols for components of a structure
&----
REPORT CHAP2403.
Table work area for later use
TABLES CUSTOMERS.
Defining a Field Symbol
FIELD-SYMBOLS <OUTPUT>.
Displaying all fields of all table entries
SELECT * FROM CUSTOMERS.
NEW-LINE.
DO.
ASSIGN COMPONENT SY-INDEX OF STRUCTURE CUSTOMERS TO <OUTPUT>.
IF SY-SUBRC 0.
EXIT.
ENDIF.
WRITE <OUTPUT>.
ENDDO.
ENDSELECT.
Reward me Points
by
Pari
03-31-2008 11:59 AM
hi,
Yes it can .... declare it as below..
FIELD-SYMBOLS: <ITAB> TYPE ANY TABLE.
03-31-2008 12:02 PM
Hi Pradeep .
Field symbols .
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.
chk here.
http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3860358411d1829f0000e829fbfe/content.htm
&----
*& Chapter 24: Using Field Symbols for components of a structure
&----
REPORT CHAP2403.
Table work area for later use
TABLES CUSTOMERS.
Defining a Field Symbol
FIELD-SYMBOLS <OUTPUT>.
Displaying all fields of all table entries
SELECT * FROM CUSTOMERS.
NEW-LINE.
DO.
ASSIGN COMPONENT SY-INDEX OF STRUCTURE CUSTOMERS TO <OUTPUT>.
IF SY-SUBRC 0.
EXIT.
ENDIF.
WRITE <OUTPUT>.
ENDDO.
ENDSELECT.
Reward me Points
by
Pari
03-31-2008 12:05 PM