You are here: Business Rules > Attached Rules > CopyToRoleFields

CopyToRoleFields

Description

This business rule allows one or more math variables or activity fields to be copied to one or more specified RoleFields upon processing the activity to which the CopyToRoleFields business rule is attached. The rule allows updates to multiple Roles. This rule must be listed in TransactionBusinessRulePacket.

CopyToRoleFields Element/Attribute Table
Element/Tag Definition Attribute Element/Attribute Value and Description

<CopyToRoleFields>

The opening and closing tag of the CopyToRoleFields Business Rule.

The attributes ROLEGUID and POLICYROLES are mutually exclusive.

 

Optional attribute;
="MathVariable"
This attribute is used to specify the ROLEGUID of the Client whose records are to be updated.
Note: Transaction to which this business rule is attached should contain the MathVariables that captures the RoleGUIDs. 

ROLEGUID

Optional: A math variable containing the value of a rule guid.

Specifies the role guid that will be updated.

POLICYROLES

Optional: A math variable containing one or more role code values.

Specifies the role codes, in a comma delimited list, that will be updated. Code values are derived from AsCodeRole.

TYPE

Optional: IFEMPTY – field must be empty (blank or null) prior to update.

Indicates that a field named in the <From> element must contain a specific value prior to the update in order to qualify for the update.

<Fields>

Required/Repeatable;
Defines a section to contain the fields that will be updated. There may be only one <Fields> element outside of the <RoleArrays> element and one for each <RoleArray> element.

 

 

<Field>

Repeatable;
Identifies the field that is updated and the updated value.

<From> and <FromCollection> elements are mutually exclusive.

 

 

<From>

Required;
Identifies the math variable or activity field as the source of the update. An activity field must be prefixed with Activity:[field name].

 

A math variable or activity field from the transaction to which the rule is attached.

<FromCollection>

Required:

Identifies a math variable of type COLLECTION as the source of the update.

 

A math variable of type COLLECTION where the keys are role GUIDs and the values are the source data.

<To>

Required:

Identifies the field that is updated.

 

A literal name for a field.

XML Sample

<CopyToRoleFields ROLEGUID="RoleGUIDToDeactivateFinal">
<Fields>
<Field>
<From>InactiveRoleCode</From>
<To>RoleCode</To>
</Field>
<Field>
<From>InactiveRoleStatus</From>
<To>StatusCode</To>
</Field>
</Fields>
</CopyToRoleFields>

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