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

BAPI + TABLE STRUCTURE

Former Member
0 Likes
1,044

Hello Friends,

I have a confusion, thought to discuss with you guys

The thing is, I have a table lets say zz_tab_1 in dict with 10 fields. Now I want to create a RFC enabled fm lets say, zz_rfc_1. This fm takes 1 importing parameter lest say, z_str_1.

This importing parameter should have all fields which are in table zz_tab_1. Now can I define the importing parameter like z_str_1 type zz_tab_1 ?

I dont think it works ? or....

I guess either I need to declare the structure in dictionary with the same feilds as table zz_tab_1, or ? is there any alternative ?

I hope I am clear enough, else ....... let me know and I will try to ask in other way

Regards,

8 REPLIES 8
Read only

Former Member
0 Likes
980

Hi,

You can give...

z_str_1 type zz_tab_1..I am pretty sure..this will work..

The only thing you have to do for RFC is you have to check the PASS BY VALUE check box for the importing and the exporting parameters..

Also let us know the error message you are getting..

Thanks,

Naren

Read only

Former Member
0 Likes
980

you can declare that in the tables structure which you can referr to your dictionary table if you want multiple line items or else if you want it as just one record you can also do that declaring as an import parameter referring to your table type. let me know if you need more info.

Read only

0 Likes
980

hi,

Thanks guys for you input, so you think I can define the importing parameter as type table ? humm... okey I am doing so, and when later I will get the error I will paste here, ..... till then...

Regards,

Read only

0 Likes
980

award points if it helps you.

Read only

Former Member
0 Likes
980

okey, lets say, I have the structre str_1, now I have to enter the values from the str into the database table ....zz_tab_1

so I can just simplay update the table zz_tab_1 with str_1 ?

Regards

Read only

0 Likes
980

yes provided they are of same structure.

Read only

0 Likes
980

hey if its solved, close the thread and award points to the helpful.

Read only

Former Member
0 Likes
980

Hi,

If the structure str is having the data type of the ddic table..Then you can use..

Ex.

DATA: STR TYPE ZZ_TABLE1.

MODIFY ZZ_TABLE1 FROM STR.

Thanks,

Naren