You are here: Business Rules > Attached Rules > AddRoles

Oracle® Insurance XML Configuration Guide Release 9.4.0.0 E18894_01

# AddRoles

## Description

The purpose of the AddRoles business rule is to add existing clients in the database to new roles on an existing policy or segment. This rule can only be attached to a policy-level transaction and can only be used to add roles to the policy on which the activity is being processed. For each role in AddRoles, at least ROLECODE and CLIENTGUID/CLIENTGUIDCOLLECTION are required. All other fields, if not specified, will be set to null. This rule must be listed in TransactionBusinessRulePacket.

Multiple roles of the same role code may be created by the rule when the configuration uses the CLIENTGUIDCOLLECTION attribute and <FromCollection> element.

Note: Reversing off an activity that uses AddRoles changes the role code of the added role to a Deleted role code. The role record should not be deleted completely.

AddRoles Element/Attribute Table
Element | Attribute | Definition
--- | --- | ---
<AddRoles> |  | The opening and closing tag of the AddRoles business rule.
<Role> |  | Required/Repeatable Element; This element is used to define the criteria for the specified roles that are added to the policy. Criteria are defined through various attributes.
| CLIENTGUID, CLIENTGUIDCOLLECTION | Required attribute: These attributes are mutually exclusive. If a single Client should be added to a particular type of role, use CLIENTGUID. If multiple Clients should be added to the same role, use CLIENTGUIDCOLLECTION.
| ROLECODE | Required attribute: The type of role the client is added to depends on the value of the ROLECODE attribute. The MathVariable must contain a valid RoleCode from AsCode=>AsCodeRole table.
| COMPANYGUID | Optional attribute: This attribute is used to specify the CompanyGUID that the newly added role should be saved with in the AsRole table.
| STATECODE | Optional attribute: This attribute is used to specify the StateCode from AsCode=>AsCodeState table that the newly added role should be saved with in the AsRole table.
| PERCENTDOLLARCODE | Attribute PERCENTDOLLARCODE will no longer be supported. While it exists in AsRole, we will copy a NULL value for that column to AsRole.
| ROLEPERCENT | Optional attribute; Used to specify the percentage of allocation for the newly added role through this business rule. Saves the specified Role Percent in the AsRole table.
| ROLEAMOUNT | Optional attribute: Used to specify the amount of allocation for the newly added role through this business rule. Saves the specified Role Amount in the AsRole table.
<Tests> |  | Optional Element; Allows configuration of Test(s) to see if a section of rule should be invoked. All conditions in this section must evaluate to true before the role(s) is/are added.
<Test> |  | Required/Repeatable Element: (Expression) Condition to add a role to the policy.
| TYPE | Optional attribute (="Expression") To indicate the type of the condition. Example: <Test TYPE="Expression">SomeMathVariable=27</Test>
<Fields> |  | Optional Element; Used to create a record in AsRoleField table by passing the required information from the transaction.
<Field> |  | Required/Repeatable Element; This tag is used to specify the values with which the newly added roles should be updated in AsRoleField table.
<From> <FromCollection> |  | Required Element value: These elements are mutually exclusive. When a single client is being added as a role, use <From>. The element accepts a field or MathVariable. When there is a potential to add multiple clients as a role, use <FromCollection>. The element accepts a MathVariable of a collection type. The keys are ClientGUIDs.
<To> |  | Required Element value: (RoleScreenFieldName) Name of the RoleScreen field.

## XML Sample

    <AddRoles>

    <Role CLIENTGUIDCOLLECTION="AddClientGUIDCollection" ROLECODE="AddRoleCodeCollection" ROLEPERCENT="RolePercentMV" ROLEAMOUNT="RoleAmountMV">

    <Tests>

    <Test TYPE="Expression">ClientCount=4</Test>

    </Tests>

    <Fields>

    <Field>

    <FromCollection>TaxIDCollection</FromCollection>

    <To>TaxIDField</To>

    </Field>

    </Fields>

    </Role>

    <Role CLIENTGUID="AddClientGUID" ROLECODE="AddRoleCode" PERCENTDOLLARCODE="" ROLEPERCENT="RolePercentMV2" COMPANYGUID="CompanyGUIDMV" STATECODE="StateCodeMV">

    <Fields>

    <Field>

    <From>TaxIDMV</From>

    <To>TaxIDField</To>

    </Field>

    </Fields>

    </Role>

    </AddRoles>

Copyright © 2009, 2011, Oracle and/or its affiliates. All rights reserved. Legal Notices

Open table of contents