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: 

'TABLES' type parameters in FM interfaces???

Former Member
0 Kudos

Hi!

Have you ever heard that in FM interfaces 'TABLES' type parameters has some disadvantages and shouldn't be used unless neccessary, and instead, importing or exporting type paramaters referenced to table types should be used?

*--Serdar

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Serdar,

interesting question. I've only heard that you should not use it in form routines ... extract from the online help for the statement form in Enterprise Release:

<b>Addition 1

... TABLES itab1 ... itabn

Effect

Instead of the TABLES addition, you should use the USING or CHANGING addition wherever possible. You can only use tables with table type STANDARD in the TABLES addition. The internal tables you specify are always passed to the FORM along with their header line. If you pass a table without header line as a TABLES parameter, the system automatically generates a header line for it. This is only valid within the FORM . You should not use any global commands (such as HIDE) on the header line. For details about specifying the type of a TABLES parameter, see specifying types. TABLES parameters are always passed by reference. </b>

May be some guys from SAP can tell us, if this is true for a FM as well.

Cheers

Jeannot

2 REPLIES 2

Former Member
0 Kudos

Hi Serdar,

interesting question. I've only heard that you should not use it in form routines ... extract from the online help for the statement form in Enterprise Release:

<b>Addition 1

... TABLES itab1 ... itabn

Effect

Instead of the TABLES addition, you should use the USING or CHANGING addition wherever possible. You can only use tables with table type STANDARD in the TABLES addition. The internal tables you specify are always passed to the FORM along with their header line. If you pass a table without header line as a TABLES parameter, the system automatically generates a header line for it. This is only valid within the FORM . You should not use any global commands (such as HIDE) on the header line. For details about specifying the type of a TABLES parameter, see specifying types. TABLES parameters are always passed by reference. </b>

May be some guys from SAP can tell us, if this is true for a FM as well.

Cheers

Jeannot

0 Kudos

I am not from SAP, but the same holds true for function modules as well.

Every tables parameter is passed with a header and incase the header is not present the system automatically creates it.

Even with function modules it is always advisable to go for import and export parameters, rather than tables parameters.

Pavan