cancel
Showing results for 
Search instead for 
Did you mean: 

Handling Response in RFC scenario..

former_member238007
Contributor
0 Kudos

Hi Experts,

I have a requirement like this...

Scenario was File to RFC in which based on the values of the response i have to give a message to the sender.

Ex: I am sending the company code.. and in response i get the details of the company from differient tables with the help of BAPI, while returning the message i dont need to send my actual details of the company instead i need to just send whether the company details are maintained or not.

if i get a response with values i have to send " Details of the Company maintained in R/3" else "Not Available"..

Can any one of u suggest some solutions with the existing node functions, or should i need to develop java function for this..

regards,

Kishore

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Kishore,

You can achieve this while Mapping u r Response Interface.

Use Message mapping Editor and based upon the Reyurn code value use the Conditional Function.

If return code is 0 : Pass Contant Value "Company Code maintained"

if return Code is 1 : Pass Constant Value "Not mainatined

rgds

srini

prateek
Active Contributor
0 Kudos

First of all, ur sender is file, therefore sync scenario us not possible without BPM or adapter modules. In both the case, u can map any structure back to sender.

Ur logic can be very well handled by the message mapping and java mapping wont be required. Based on some value present in the RFC response, u may map some constant value to sender saying "Details Maintained". And if value of field does not exist, map constant saying "Details not Maintained".

Regards,

Prateek

former_member238007
Contributor
0 Kudos

Raj,

Can u elaborate more on that...

How should i handle a MESSAGE whether data is maintained in R/3 or not, why because only the values of the BAPI can be caught at mapping level i dont want those values instead i need to return a message whether data is available or not..

can u explain for this example which functions are to be used in the message mapping..

Sender structure:

EmpNo-- I am sending the name

Target structure:

It takes EmpNo as input and checks with the differient tables of R/3 if it is present it should return the following

Response Structure :

Returns Name, Department, Salary, Designation

But where as i need to send the details whether "Record is New" or "Record all ready present", i dont need all the values such as Name, Department, Salary, Designation..

provide some inputs regarding to this..

regards

Kishore

Former Member
0 Kudos

Hi Raj,

Normally bapi would have return code based upon your Data upload or availabilty.

Well capture this message in the Message Mapping Editor , use boolen Fucntion use if else then type.

Use constant text when it statisfies the return code.

If u want more string statement as outpur.

use UDF

Would serve u.

rgds

srini