cancel
Showing results for 
Search instead for 
Did you mean: 

Retrieving SID in Java Mapping

Former Member
0 Kudos

Hi SDNers,

In my current assignment I am required to fetch the SID of the PI system on which the map is running and take some action based on this SID. My mapping is a JAVA Mapping.

How can I fetch SID of the system at runtime?

Using StreamTransformationConstants I can fetch the parameters mentioned [here|http://help.sap.com/saphelp_nw04/helpdata/en/43/09b16006526e72e10000000a422035/frameset.htm]

but these parameters do not include SID.

Kindly throw some light on this.

Regards,

Gautam Purohit

Accepted Solutions (1)

Accepted Solutions (1)

Shabarish_Nair
Active Contributor
0 Kudos
String systemID = java.lang.System.getProperty("SAPSYSTEMNAME");

// Get the SID
String sysNam = (String) System.getProperty("SAPSYSTEMNAME");

if(sysNam.equals("<XID>")){
//your logic
}
else if(sysNam.equals("<XIQ>")){
//your logic
}
...
...
...

that should be the logic.

Former Member
0 Kudos

Hi Shabarish,

Thanks a lot for the reply.

Regards,

Gautam Purohit

Answers (0)