Sterling OMS First Static Condition

Sterling OMS First Static Condition
Condition:
In Java we can write below logic for displaying age.
private printAge(int age) {
if (age == 30) {
System.out.println(“Your age is 30”);
} else if (age == 31) {
System.out.println(“Your age is 31”);
} else {
System.out.println(“Your age is > 31”);
}
}
How to do the similar logic in Sterling OMS? In this post we are going to see different ways of implementing condition.
OMS Condition in simple words: Condition can change the system flow based on input XML attribute values.
OMS Condition Definition: The document type XML attributes against which conditions can be created are pre-defined in Sterling Order Management. Based on the decision points and routes the document to the appropriate path.
Where Condition used in OMS:
- Hub Rule
- Pipeline
- Service
- Transactions – Event Handler

Different Types of Condition in OMS:
- Static Condition : Using Sterling Condition builder we can create condition
- Dynamic Condition : Using Java code we can create condition
- Advanced XML : Condition created using the Sterling Greex Editor
Where to Configure Condition in Application Manager:
- Login into OMS application
- Go to application manager
- Applications – Application Platform
- Process Modelling
- Click any tab (Example Order) and click on any one of Process Types (Example Order Fulfillment)

- Create Condition – Right click on Conditions menu
- Using statement builder build condition as shown below (Select Enterprise and Ship Node from Choose Field Menu option)

- Click OK
- Click Save
How to configure static condition?
- Create New Service with name “StaticCondition” as shown below

- Add Condition from API components
- Select Condition Name as Static Condition
- Add Database component from Transport Types section
- Select table name as shown below

How to test the static condition?
Using HTTP API tester test the newly created service (How to use HTTP Tester ?)
| Input XML | Service to call | Result |
| <Order EnterpriseCode=”Matrix” ShipNode=”Matrix_WH1″ /> | StaticCondition | No record inserted into YFS_EXPORT table; enterprise code attribute value is not matching |
| <Order EnterpriseCode=”Matrix-R” ShipNode=”Matrix_WH1″ /> | StaticCondition | Record created because both attribute matched |
Please share your feedback with us at support@activekite.com
Please provide examples of advanced XML condition
And custom condition.
Hi Ravi
We are working on custom conditions. Advanced XML we have not used. May be some one else can help on that.
Pingback: Sterling OMS Writing First Dynamic Condition - Learn IBM Sterling Order Management System