Rules Configuration (.rba)
Rules Based AdapLink (RBA) provides a framework for creating, editing and testing
rules applied to data.
- RBA is a key enabler for AdapChain’s Rules Based data methodology.
- RBA plays a key role in both data integration projects and in data management
projects.
Criteria
Rba Criteria is a group of conditions. Condition is made up of
Counter,
Object,
Option + “Option Nature”,
Min and Max.
Note
If a Criteria has no conditions then it is considered to be
True.
Counter
Counter allows us to group conditions using AND and OR.
- Counters with the same number are treated as AND.
- Counters with different numbers are treated as OR.
- The result of each Counter is ORed at the end of processing a Criteria.
- This final ORed result determines if the Criteria is
True
or
False.
Note
Only when the Criteria is evaluated to
True
then the Assignments are executed.
Object
Object forms the left hand side of the condition.
Object contains either an expression or an Object Field Name.
- If the data starts with equal sign ‘=’ it is considered to be an
expression. The result of the evaluation is then used on
the left hand side of the condition.
- If the above condition is not met then the data is considered to be an
‘Object Field Name’, whose value is retrieved and used on the left hand side
of the condition.
Option + “Option Nature”
Option + “Option Nature” represents an operator in the condition.
An “Option Nature” defines the comparison mode (String / Number)
- If “Option Nature” is Number then the final values to be compared are automatically converted to
Number and then compared.
- If “Option Nature” is String then the final values to be compared are automatically converted to
String and then compared.
| Option |
Operator |
Type |
Example |
| BT (Between) |
Object >= Min and Object <= Max (Note: Min and Max are inclusive) |
|
|
| IN (In) |
Object in Min |
Array |
={“10”,”20”,”30”} |
| !IN (Not In) |
Object not in Min |
Array |
={“10”,”20”,”30”} |
| EQ (Equal) |
Object == Min |
|
|
| NE (Not Equal) |
Object != Min |
|
|
| GE (Greater than or equal to) |
Object >= Min |
|
|
| GT (Greater than) |
Object > Min |
|
|
| LE (Less than or equal to) |
Object <= Min |
|
|
| LT (Less than) |
Object < Min |
|
|
Min and Max
Min and Max form the right hand side of the condition.
Min and Max contains either
String,
or an expression.
- If the data starts with equal sign ‘=’ it is considered to be an
expression.
The result of the evaluation is then used on the right hand side of the
condition.
- If data is not an expression then the data is considered as
String
and used as it is.
Note
Irrespective of the operator both Min and Max are always processed. For example
operator EQ requires only Min to be set, but if an expression
was present in Max, it will be evaluated even though EQ does not require it.
Assignment
Assignments are mainly used to set values for Object Fields.
Note
Assignments are processed only if the Criteria is
True.
- An Assignment is made up of Object and Value.
- The Object contains ‘Object Field Name’ against which the value is stored.
Note
If Object does not contain an Object Name then the value is evaluated but not
stored.
Value
- If the data starts with equal sign ‘=’ it is considered to be an
expression.
The result of the evaluation is then used on the right hand side of the
assignment.
- If data is not an expression then the data is considered
as String
and used as it is.