A Rate Component with Service Type Comparison
Imagine a rate component that is only eligible if the current customer has gas service AND electric service. This rate component would need the following eligibility rules:
- Customer has gas service, and
- Customer has electric service
These rules require only one eligibility group on the rate component. It would looks as follows:
Group No. |
Group Description |
If Group is TRUE |
If Group is FALSE |
1 |
Has gas service AND electric service |
Apply rate component |
Skip rate component |
The following criteria will be required for this group:
Group 1: Has gas service AND electric service |
|||||
Seq |
Field to Compare |
Comparison Method |
If TRUE |
If FALSE |
If Insufficient Data |
10 |
Algorithm: check if customer has gas service |
= TRUE |
Check next condition |
Group is false |
Group is false |
20 |
Algorithm: check if customer has electric service |
= TRUE |
Group is true |
Group is false |
Group is false |
Both criteria are similar - they call an algorithm that performs a logical comparison. These algorithms are a bit counter intuitive (but understanding them will provide you with another way to implement complex eligibility criteria):
Both criterion works as follows:
- Field to Compare. We chose a "field to compare" algorithm that checks if the current account has service agreements that belong to a given set of service types. It returns a value of TRUE if the customer has an active service agreement that matches one of the service types in the algorithm. In our example, the "check if customer has gas service" algorithm returns a value of TRUE if the customer has at least one active service agreement whose SA type references the gas service type. The "check if customer has electric service" algorithm is almost identical, only the service type differs. Refer to the RECF-SRVTY and RECF-AUTOPAYalgorithms for examples of this type of algorithm.
- Comparison Method. We simply compare the value returned by the algorithm to TRUE and indicate the appropriate response.
Bottom line. The "field to compare" algorithm isn't actually returning a specific field's value. Rather, it's returning a value of TRUE or FALSE. This value is, in turn, compared by the "comparison method" and the group is set to true, false or check next accordingly.