cancel
Showing results for 
Search instead for 
Did you mean: 

Function module

madan_ullasa
Contributor
0 Kudos

Hi frnds...

i have to pass say just 3 - 4 fields of a table from a function module. how do i declare it in the "tables" parameter.

eg. i have a itab with fields 'matnr', 'mbrsh','mtart' in the function module. how do i export it from the function module in the form of a table.

points assured for all answers...

regards,

Madan......

View Entire Topic
Former Member
0 Kudos

Hi Madan,

I hope this solves you to export the internal table with out declaring in dictionary.

Declare the itab in the TABLES tab of your FM with out any reference.

It means it is a text type internal table with one column.

Concatenate all the fields you want to export into

the table with some separator in the FM.

Now in the program after exporting the internal table from the FM, the table with the separator and map into your corresponding internal table of the program.

I hope it helps you.

regards,

Gopi.

madan_ullasa
Contributor
0 Kudos

hey gopinath,

plz elaborate a bit...

i assure u 10 points :):):)

madan...

alex_m
Active Contributor
0 Kudos

Hai! Madan.

The batter way is to declare a structure in dictionary then use it in your tables parameter. The second one suggested by gopinath its ok but u need more code while u r passing the records and while using also.

Alex

Former Member
0 Kudos

Hi Madan,

Please go thru the GUI_Upload FM, there he has done declaration in the internal table. You need to do in the same way.

Consider how u pass the internal table data for GUI_UPLOAD with unix file format. same way you consider here also.

I hope it clears you.

Regards,

Gopi.