Showing results for 
Search instead for 
Did you mean: 

UDF -Golobal variables to store the data

Former Member
0 Kudos


We are sending order information to source system (SAP).

Here i need to chk in message mapping : if it is the

first time we received that order into SAP or not.

As per the expert suggestion its better to use global variable and store the order no and compare it the next time it comes.

Let me know the UDF code.



Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

As far as I can tell, I don't think the information in the global container is persisted so if for some reason your Java engine is restarted, this information will be lost.

I think you should use BPM to make a request to the SAP system to determine whether it has alrady been sent and then proceed with your normal processing.

Another option is to use a simple BPM to do your scenario (without making a call to SAP) and maintain your information in a multiline container and use that container to do the check. Remember, all scenarios should then go through a single instance of the BPM. This way the information will be persisted.



Former Member
0 Kudos


Refer below blog


Here you can maintain the Global variable and then in 1st mapping assign the value for it as had shown in UDF code in blog and then innext mapping check the value of global variable. per your suggestion I doubt how you will maintain multiple order information in Global variables.

Better to go for Either DB / RFC Lookup here you can maintain the table and can check from it whether the Order information is previously send or not

For db/rfc lukup refer to:

Lookup’s in XI made simpler : DB lukup


RFC Mapping Lookups