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

Data Declarations in a program

Former Member
0 Likes
809

Hi Frnds,

I am having a requirement to collect all the data declarations in a program ( Global variable, Internal table ..). How can we get the data declaration's in a program. please help me. Thanks.

1 ACCEPTED SOLUTION
Read only

uwe_schieferstein
Active Contributor
0 Likes
753

Hello Anand

Obviously there should be standard function around because when you display a report in SE80 and open the folder Fields in the tree view you can see all global data definitions.

A useful function module is RS_PROGRAM_INDEX. The TABLES parameter COMPO returns all components of your program object:

Type D = data definition

Regards

Uwe

4 REPLIES 4
Read only

Former Member
0 Likes
753

Hi,

You can check the data declarations in an include which ends with TOP or some other custom include.

or else you need to find it manually.

Usually there is a standard of declarations in the top include for any program. If you are following the same then you can find it over there.

Regards,

Venkatesh

Read only

Former Member
0 Likes
753

try out these fm's

GET_COMPONENT_LIST -- Detailed description of fields from programs

GET_GLOBAL_SYMBOLS -- Returns all components of a program

also try this fm

GET_INCLUDETAB

it will give u all includes

кu03B1ятu03B9к

Edited by: kartik tarla on Jan 7, 2009 11:28 AM

Read only

0 Likes
753

Thanks kartik,

Get Global Symbols fm is working fine. But having one small problem with it,

It is listing some other standard fields with the declared fields in output.How to remove those unwanted entries.

From the list of variable retrieved from the em, How can i differntiate the list with global variable, Internal table and workarea for an internal table.

Like global variable,whether there is any function module for local variables. Thanks a lot.

Read only

uwe_schieferstein
Active Contributor
0 Likes
754

Hello Anand

Obviously there should be standard function around because when you display a report in SE80 and open the folder Fields in the tree view you can see all global data definitions.

A useful function module is RS_PROGRAM_INDEX. The TABLES parameter COMPO returns all components of your program object:

Type D = data definition

Regards

Uwe