cancel
Showing results for 
Search instead for 
Did you mean: 

Getting XI business system name Dynamically

Former Member
0 Kudos

Hi All,

I am using RFC lookup for one of our project requirment. we will be using one of our inputs as business system which hosts the RFC function module (RFC_READ_TABLE). in our dev it is our XI business system. But when we move these objects to quality or prod, this mapping fails because the name of the XI business system changes. Can anyone suggest me how we can get the xi system name dynamically.

Best Regards,

Deepika

Accepted Solutions (1)

Accepted Solutions (1)

Shabarish_Nair
Active Contributor
0 Kudos

a simple way to identify the XI system from within a mapping is;



//retrieve SID
String sysName = (String) System.getProperty("SAPSYSTEMNAME");
 
 
if(sysName.equals("XXX"))
{
//your logic here
}
else if ()
.....
.....
....
...

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Deepika

You can use the function "Sender" or "Receiver" (depending upon whether your business system is sender or receiver) which is available under 'Constants' category in Standard funtions of Graphical mapping.

These functions give the current value of the businees system in the environment where the interface is running.

Let me knwo if you are still not able to pick it.

Thanks

Ram

Former Member
0 Kudos

Hi Ram,

Apart from the sender and receiver business system, I am using XI system for hosting the rfc module and database table.

Best Regards,

Deepika

Former Member
0 Kudos

Hi,

Try this in your UDF, it will fetch you the system id :

System.getProperty("SAPSYSTEMNAME");

Regards,

Pragati

udo_martens
Active Contributor
0 Kudos

Hi,

you can use a ABAP mapping and ask for system variable SY-SYSID. Depending from that you set the BS.

You dont need ABAP dom for such simple cases. Use FM ECATT_CONV_XSTRING_TO_STRING to get a string from input and finally convert the result string back to XSTRING with ECATT_CONV_STRING_TO_XSTRING. Use ABAP expression REPLACE REGEX (with regular expression) for replacing the BS.

Regards,

Udo