‎2008 Jun 30 1:30 PM
Hi gurus,
Is it possible to define a hashed (or sorted) table as an export parameter in a function module?
Thanks!
‎2008 Jun 30 1:39 PM
Hi,
Sorted table is possible.
Not sure about hashed one.
regards,
Prosenjit.
‎2008 Jun 30 1:54 PM
‎2008 Jun 30 1:50 PM
Hello Bin Wang,
The actual parameter need only have the selection of attributes possessed by the formal parameter. The formal parameter adopts its remaining unnamed attributes from the actual parameter.
TYPE SORTED TABLE: The system checks whether the actual parameter is a sorted table. The formal parameter inherits all of the attributes (line type, key) from the actual parameter.
TYPE HASHED TABLE: The system checks whether the actual parameter is a hashed table. The formal parameter inherits all of the attributes (line type, key) from the actual parameter.
You should use USING or CHANGING instead of the TABLES addition for internal tables, although for performance reasons, you should not pass them by value.
Hope you find it useful
Regards
Indu.