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

how to test a RFC ?

Former Member
0 Likes
20,943

hi ,

i was asked in an interview...that how we can test the RFC..?

please can any body help me on this...

thanks

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
15,275

Hello,

I hope you know how to create a RFC.

Use transaction SM59 to create RFC connection. Now after creating RFC there is a button on the top of the screen "Test Connection", you can click the button,and if the connection is established properly then you will get one more screen with connection timings details.

Regards

Arindam

4 REPLIES 4
Read only

Former Member
0 Likes
15,276

Hello,

I hope you know how to create a RFC.

Use transaction SM59 to create RFC connection. Now after creating RFC there is a button on the top of the screen "Test Connection", you can click the button,and if the connection is established properly then you will get one more screen with connection timings details.

Regards

Arindam

Read only

uwe_schieferstein
Active Contributor
0 Likes
15,275

Hello

Does RFC mean the "RFC destination" or the RFC function module?

I assume the interviewer asked for the first one because the latter one just means to call a function module remotely.

RFC destination can be tested using transaction SM59 (connection test, Unicode test, authorization test).

Programatically you may use RFC-fm RFC_GET_SYSTEM_INFO using this RFC destination in order to retrieve some technical information about the target system.

Since RFCs may fail due to connection / authorization problems you need to call them in the following way:

CALL FUNCTION 'RFC_GET_SYSTEM_INFO'
    DESTINATION <rfc_dest>
    ...
    EXCEPTIONS
      system_failure = 1 MESSAGE ld_msg
      connection_failure = 2 MESSAGE ld_msg
      others = 3.

The first two exceptions are standard RFC exceptions. If the RFC fails you find the message text in LD_MSG.

Finally, how do you know that your RFC destination is correct?

Example: RFC destination E01CLNT100 is thought to connect to client 100 of system E01. This client has the represents the logical system E01CLNT100.

In order to check this you can call RFC-fm PARTNER_LOGICAL_SYSTEM_GET on the remote system.

IF the returned logsys is not the expected one then there is something wrong with the technical settings (e.g. wrong system number, wrong IP address).

Regards

Uwe

Read only

Former Member
0 Likes
15,275

Hi Santoshi,

Did you check this link? Hope it will be helpful for you.

http://help.sap.com/saphelp_nw04s/helpdata/en/be/6e0f41218ff023e10000000a155106/frameset.htm

Thanks

Nitesh

Read only

Former Member
0 Likes
15,275

Thanks...i got it.