Application Development 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: 

How to define the TYPE of the internal table, so that it behaves variantly

Former Member
0 Kudos

hi

i am calling the functiopn module HR_READ_INFOTYPE in a seperate function module.

Every time while calling, i need to pass different infotypes.

So call to the subroutine becomes..

CONSTANTS :c_0000 type CHAR4 value '0000'.

DATA it_p0000 type STANDARD TABLE OF p0000.

PERFORM read_infotype using PERNR c_0000

changing it_p0000.

FORM read_infotype using p_pernr type PERSNO

p_c_nnnn type char4

changing p_it_pnnnn type any.

Here p_pernr will be the PERNR.

p_c_nnnn is a constant which will be having the infotype value. and it_pnnnn will be internal table of type STANDARD TABLE OF 'structure of respective infotype'

Now my question is

p_it_pnnnn will be of different table each time i pass its value with different infotype structures.

so in place of 'any' ( CHANGING p_it_pnnnn type any.) i need to provide a valid type for the Internal table..

What should be its TYPE ?

Thanks & Regards

Manjari

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi manjari,

Instead of any you can also give Standard Table.

Regards

Karthik D

1 REPLY 1

Former Member
0 Kudos

Hi manjari,

Instead of any you can also give Standard Table.

Regards

Karthik D