Skip to Content
Technical Articles
Author's profile photo Punith Oswal

Cloud Integration – How to dynamically use a Global Variable in the other Integrations across the Tenant

Hello SAP Experts,

This is my first blog on Cloud Integration where I will try to focus on the use of Global Variable in a dynamic way across the Tenant.


There are scenarios in which we need to use the same variable in many of the Integration and if there are any changes to this variable, the variable has to be changed in all the Integration, changing the variable in all the Integrations and deploying the flow again manually is a tedious task.


One example of such case is Location ID, we use the Location ID parameter in the adapter where we intend to communicate with the On Prem systems. This parameter is used mostly in all the integration across the tenant and if there is any change in the value of Location ID, it is required to visit all the Integration and the values needs to be updated one by one, this is a challenge nowadays.


To mitigate this, I have come up with a solution wherein we can use this parameter globally across the tenant and can be updated anytime without touching the main integrations.


Here are the steps:

Lets consider a variable called “LocationID” which is being used in most of the Integration which has value called “India”.

We will create a Integration Flow, where we will store this variable as Global Scope.


  • Configure Global Variable Integration Flow:

  • Content Modifier: Please note that the value of LocationID is set as configurable parameter, so if there are any changes in the value of this parameter, it can be changed at any point of time.


  • Write Variables: The variable LocationID is declared as Global Scope so that it can used across the tenant.

After this Integration Flow is deployed, the variable can be seen in the variable monitoring tile with scope as Global.



The Basic task of declaring the variable as Global is now achieved, now we will see how to use this variable in the other flows.

In the other flows, we just have to call this variable in the content modifier, create a variable with any name, I have used LocationID as the name here, set the type as “Global Variable” and assign the value same as the Global Variable name.


Other Integration Flows:


Now this variable is ready to be used in the Integration flow anywhere you want, you can use in the adapter steps by calling ${property.LocationID}.


In the future if there are any changes to this value, you just have to go that “Configure Global Variable” Integration Flow, configure the new value and deploy it, the value will be updated in all the Integrations across the Tenant.


This is a simple concept but can be can very useful, I hope this helps.


Thank You!!!

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Naresh Dasika
      Naresh Dasika

      Great blog. Well explained.

      Author's profile photo kunal Singla
      kunal Singla

      Hi All,

      In one scenario we are using Global Variable to store SessionID then Fetching Same SessionID for multiple messages at the same time. SAP Global Variable it seems are not able to fetch SessionID for High number of messages at same time.

      Error Faced - org.springframework.transaction.CannotCreateTransactionException: Could not open JDBC Connection for transaction; nested exception is org.postgresql.util.PSQLException: ERROR: current transaction is aborted, commands ignored until end of transaction block, cause: org.postgresql.util.PSQLException: ERROR: cannot execute DELETE in a read-only transaction"

      Can you suggest if there is any limitation on this.

      Author's profile photo Ahmad Shaik
      Ahmad Shaik

      Hi Punith,

      Thanks for this blog. It's working fine.

      But some parameters were maintained wrong.