Example: Definition of a Single Set of Rules
You want to define a set of rules that assigns R phrase R10
(Flammable
) to characteristic R Phrases
of value assignment type Indicator
for substances with a flash point of between 21 and 55 °C. Value assignment type flash point should only contain one data record; in other words, can only be assigned a single value.
Start the rule editor and create a new rule (see Using the Rule Editor).
Under Description
, enter a description of the rule, e.g. Derivation of R phrase from flashpoint.
In the Condition
field, enter the first part of the condition: 21 <.
From the overview tree, select the characteristic Value
of value assignment type Flash point
and, using drag and drop, assign it to the Condition (IF)
field.
In the Condition (IF)
field, you will now see 21 < FLAMMP_WERT.
Complete the condition in the Condition
field as follows: 21 < FLAMMP_WERT, FLAMMP_WERT < 55.
From the overview tree, select the characteristic R Phrases
of value assignment type Indicator
and, using drag and drop, assign it to the Left Expr.
field.
Internal fact key KENNZ_R_STZE appears in the Left Expr.
field and the system automatically inserts the operator := in the ToDo
field.
From the overview tree under characteristic R Phrases
of value assignment type Indicator
, select the phrase Flammable
and, using drag and drop, assign it to the Right Expr.
field.
Internal phrase key "[#R10#]" appears in the Right Expr.
field.
Save the set of rules.
The rule file (<Name>.rul) has the following structure:
Structure of example | ||
|---|---|---|
FACTS | ||
KENNZ_R_STZE(OUT), | ||
FLAMMP_WERT(IN) | ||
;Rules | ||
RULES | ||
RULE NEWRULE1 | ||
DESCRIBE "Derivation of R phrase from flash point" | ||
IF 21 < FLAMMP_WERT, FLAMMP_WERT < 55 | ||
THEN | ||
KENNZ_R_STZE := "[#R10#]" | ||
END | ||
END | ||