cancel
Showing results for 
Search instead for 
Did you mean: 

RFC calling issues

Former Member
0 Kudos

Hi,

I have developed RFC function module in R/3 system, with import, export and return parameters.(return parameters are for returning errors).When I execute this RFC function module alone, RFC function module is returning values.and if there is no values found for a given input,it is returning errors in a return table.

It is working fine. if I execute it alone.

When I call this RFC function module from SCM system, it is not returning any values,though the output exist for a given input. it is juct returning blank values. If there is no output exist for a given input, then it is returning erorrs in a return table.

Can anyone please tell me what would be the error.

Thanks&Regards

Rama.Mekala

Accepted Solutions (0)

Answers (3)

Answers (3)

vinod_vemuru2
Active Contributor
0 Kudos

Hi Rama devi,

By this way we can't say problem is with SAP end or with SCM end. There might be data conversion problems between SAP and Non SAP

ends. We have similar problems with currency fields where we got correct values from SAP and incorrect values when transfered to non SAP. After that we took some temporary variables to fix these issues.

What u have to do is Debug ur RFC from SCM system. Then only u can figureout where exactly problem lies. There are special tools available to debug the RFC fron Non sap systems. Check with ur Non SAP team on how to debug ur code from SCM system. There should be proper coordination between SAP and Non SAP teams to fix these types of issues.

Hope this info will help u.

Thanks,

Vinod.

Former Member
0 Kudos

Hi Vinod,

In my case, I am not even able to debug the function module.

what my doubt is do I need to create RFC function module in both the calling and called system.

Thanks&Regards

RamaDevi

vinod_vemuru2
Active Contributor
0 Kudos

Hi Rama Devi,

If we create the RFC in calling system also then there is no need of RFC itself:-).

Only we need to establish connection between the systems and this will be done by ur BASIS team.

As u told even from SCM system u r able to see error messages(In return table) there should not be any problem with the connection.

Why can't u debug the FM.? What is the issue u r facing

in debugging? There should be some setting done from SCM system to debug SAP code from their system. Have a chat with ur Non SAP team. U alone can't do it because debugging has to be done from non SAP end. While they debug their code, When the control enters at calling point of ur FM then SAP screen will popup for userID and password. Ask them to enter ur user ID n pw. Now u can take the control and debug ur FM and see what is happening. If both teams are located at same place then sit together n solve the issue. If at different locations then u can try with Net meeting.

Important things to check is Input ur getting and output u r passing. They may pass the correct values, but u may receive junk values. Similarly u may output correct data,

they may receive junk/blank data

Thanks,

Vinod.

Former Member
0 Kudos

Hi vinod,

thanks for reply,

Now I could able to resolve the issue.by debugging RFC.

One more question I have

How can we display multiple error messages in Return table.

I am getting only one error message in return table.

Can you please reply for this. as I need to deliver it today.

thanks&Regards

Rama Devi

vinod_vemuru2
Active Contributor
0 Kudos

Hi Rama Devi,

How u declared ur Return table. Is it under TABLES parameter.

U have to declare it under TABLES parameter.

In ur FM source code append all the error messages in to this

table. This will finish ur job. Return table structure???

If u want ur cusom structure then create the same in SE11 and refer ur return table(In tables parameters) to that structure. Otherwise u can refer to standard structure BAPIRET2.

Thanks,

Vinod.

gopi_narendra
Active Contributor
0 Kudos

You should call the function module in this way

data : DEST type RFCDES-RFCDEST.

call function 'RFC_FM' destination DEST " DEST is the RFC destination name maintained in SM59.

exporting

.....

importing

.......

exceptions

.....

if sy-subrc <> 0.

endif.

Regards

Gopi

Former Member
0 Kudos

I have maintained RFC destination

former_member156446
Active Contributor
0 Kudos

Hi when you call it in a program you need to mention the destination in the function module...

call function 'RFC_CALCULATE_TAXES_DOC'
destination cl_vertex
exporting
i_sap_control_data = ....

LETS SEE the code..

Edited by: Jackandjay on Jun 16, 2008 10:38 PM