23Migrating Assignment Rule Groups and Assignment Rules

Migrating Assignment Rule Groups and Assignment Rules

Assignment Manager

You can configure the assignment manager in Oracle CRM On Demand to automatically assign leads, opportunities, service requests, or accounts to the appropriate person, team, or territory, based on the criteria that you configure on the assignment rules and the order in which the rules are evaluated within the assignment rule groups. Assignment rules and rule groups are supported only for the Account, Lead, Opportunity, and Service Request record types. For more information about assignment rules and rule groups, see Oracle CRM On Demand Online Help.

Assignment Rule Groups

An assignment rule group is a set of assignment rules for a specific record type, that are evaluated according to the order specified on the rules within the group. You can create multiple assignment rule groups for a record type, but only one assignment rule group can be active for a record type at any time.

The following table describes the Oracle Migration Tool On Demand client commands that are used with assignment rule groups. The commands are case sensitive. For examples of running these commands, see Migrating Assignment Rule Groups.

Table Oracle Migration Tool On Demand Commands for Assignment Rule Groups

Command Description

Read AssignmentRuleGroup [SystemNameOfObject] [RuleGroupName]

This command extracts all of the assignment rule groups for a specific record type (object), or a single assignment rule group (if the RuleGroupName parameter is specified). The parameters for the command are as follows:

  • SystemNameOfObject is the system name of a record type (object). The system names for the record types are listed in System Names for Record Types. If you specify a rule group name in the command, then you do not need to specify a record type, but you must include an empty value for the SystemNameOfObect parameter. An empty value is specified as a set of double quotation marks ("").

  • RuleGroupName is name of a specific rule group. You can extract an individual assignment rule group by specifying a value for the RuleGroupName parameter.

ReadAll AssignmentRuleGroup

This command extracts all assignment rule groups, for all record types.

Upsert AssignmentRuleGroup AssignmentRuleGroupXML

This command inserts an assignment rule group (if it does not already exist) or updates an assignment rule group (if it already exists).

Assignment Rules

An assignment rule automatically assigns a lead, opportunity, service request, or account to the appropriate person, team, or territory, based on the criteria that you configure on the assignment rule. The following table describes the Oracle Migration Tool On Demand client commands that are used with assignment rules. The commands are case sensitive. For examples of running these commands, see Migrating Assignment Rules.

Table Oracle Migration Tool On Demand Commands for Assignment Rules

Command Description

Read AssignmentRule [SystemNameOfObject] [RuleGroupName] [RuleName]

This command extracts all of the assignment rules for a specific record type (object), or all of the rules within a rule group, or a single assignment rule, depending on the parameters you specify. You must specify at least one of the following parameters:

  • SystemNameOfObject is the system name of the record type (object). The system names for the record types are listed in System Names for Record Types. If you specify a rule group name or a rule name with the command, then you do not need to specify a record type, but you must provide an empty value for the SystemNameOfObect parameter. An empty value is specified as a set of double quotation marks ("").

  • RuleGroupName is the name of an assignment rule group to which a rule belongs. If you specify the rule name, then you do not need to specify the rule group name, but you must provide an empty value for the RuleGroupName parameter.

  • RuleName is the name of a rule. You can extract an individual assignment rule by specifying a value for the RuleName parameter.

ReadAll AssignmentRule

This command extracts all assignment rules in all assignment rule groups, for all record types.

Upsert AssignmentRule AssignmentRuleXML

This command inserts an assignment rule (if it does not already exist) or updates an assignment rule (if it already exists).

Privileges Required for Migrating Assignment Rule Groups and Assignment Rules

The following privileges are required for the user account running the Oracle Migration Tool On Demand client commands:

  • For the Read and ReadAll commands: Enable Web Services Access, and Data Rules and Assignment.

  • For the Upsert command: Enable Web Services Access, and Data Rules and Assignment.

For information about setting and checking privileges, see Oracle CRM On Demand Online Help.

Elements and Sections in the Assignment Rule Groups Output File

The following table describes the elements and sections in the assignment rule groups XML output file.

Table Elements and Sections in the Assignment Rule Groups XML File

Description Element or Section

The <AssignmentRuleGropup> section contains all of the information for a single assignment rule group.

<data:AssignmentRuleGroup>
. . .
</data:AssignmentRuleGroup>

<RecordType> contains the system name of the record type (object), which never changes.

<data:AssignmentRuleGroup>
. . .
  <data:RecordType>Service Request
  </data:RecordType>
. . .
</data:AssignmentRuleGroup>

<RuleGroupName> contains the name of the assignment rule group.

<data:AssignmentRuleGroup>
. . .
  <data:RuleGroupName>SRTestGroup
  </data:RuleGroupName>
. . .
</data:AssignmentRuleGroup>

<Active> specifies whether this assignment rule group is active (true) or inactive (false).

<data:AssignmentRuleGroup>
. . .
  <data:Active>false</data:Active>
. . .
</data:AssignmentRuleGroup>

<UnassignedOwner> contains the User Sign In ID of the user who inherits the records that are not assigned by one of the rules in the rule group. This element is required.

<data:AssignmentRuleGroup>
. . .
  <data:UnassignedOwner>
   EXAPMLECOMPANY/TESTUSER
  </data:UnassignedOwner>
. . .
</data:AssignmentRuleGroup>

<UnassignedTerritory> is the territory that inherits the records that are not assigned by one of the rules.

The <UnassignedTerritory> element is applicable for assignment rule groups for the Account and Opportunity record types only. This element is ignored for upsert requests for assignment rule groups for other record types.

<data:AssignmentRuleGroup>
. . .
  <data:UnassignedTerritory/>
. . .
</data:AssignmentRuleGroup>

<ReturnEmail> is the email address that appears in the Sender field in the email notifications that are sent to the owners of leads and service requests when the records are assigned to them by the assignment manager. Also, if the record owner replies to the email, then the To address in the return email is set to this email address.

The <ReturnEmail> element is applicable for assignment rule groups for the Lead and Service Request record types only. This element is ignored for upsert requests for assignment rule groups for other record types.

Note: You can optionally turn off the email notification for individual assignment rules for the Service Request record type, by setting the <EmailNotification> element on the rule to false. You cannot turn off the email notification for assignment rules for the Lead record type.
<data:AssignmentRuleGroup>
. . .
  <data:ReturnEmail>test.sender@example.com
  </data:ReturnEmail/>
. . .
</data:AssignmentRuleGroup>

The <ListOfRule> section contains details of the rules for the rule group.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

The <AssignmentRule> section contains all of the top-level details for one rule in the rule group.

Note: The team assignment and criteria information for a rule is not contained in the assignment rule group XML file. The team assignment and criteria information for a rule is contained in the assignment rule XML file only.
<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
    <data:AssignmentRule>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

<RuleName> contains the name of the rule.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
    <data:AssignmentRule>
     <data:RuleName>SRRule1</data:RuleName>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
</data:AssignmentRuleGroup>

<Order> is the order number for the assignment rule within the rule group. It determines the order in which the assignment manager invokes a sequence of assignment rules. The rule numbered 1 is invoked first, followed by the rule numbered 2, and so on.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
    <data:AssignmentRule>
. . .
      <data:Order>1</data:Order>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

<AssignTo> contains the User Sign In ID of the user to whom the record is assigned if the criteria on the rule are met. When the criteria on one rule are met, the record is assigned and subsequent rules are ignored.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
   <data:AssignmentRule>
. . .
     <data:AssignTo>EXAMPLECOMPANY/TESTUSER2
      </data:AssignTo>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

The <EmailNotification> element specifies whether an email notification is sent to the user to whom the record is assigned (true) or an email notification is not sent to the user (false). The default value is true.

The <EmailNotification> element can be set to false for assignment rules for the Service Request record type only. This element is ignored for upsert requests for assignment rules for other record types.

Note: You cannot turn off the email notification for assignment rules for the Lead record type. No email notifications are sent for account and opportunity assignments, even if the <EmailNotification> element is set to true.
<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
   <data:AssignmentRule>
. . .
      <data:EmailNotification>true
      </data:EmailNotification>
. . .
     </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

<AssignToTerritory> is the territory to which the record is assigned if the criteria on the rule are met.

The <AssignToTerritory> element is applicable for assignment rules for the Account and Opportunity record types only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
   <data:AssignmentRule>
. . .
      <data:AssignToTerritory/>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

<IncludeTeamAssignment> specifies whether the team members are assigned to the record (true), or the team members are not assigned to the record (false).

The <IncludeTeamAssignment> element can be set to true for assignment rules for the Account and Opportunity record types only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
    <data:AssignmentRule>
. . .
      <data:IncludeTeamAssignment>false
      </data:IncludeTeamAssignment>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

<IncludeRelatedContacts> specifies whether the contacts that are linked to the account are assigned to the specified account owner and territory if the rule criteria are met (true), or the contacts that are linked to the account are not assigned to the specified account owner and territory (false). The default value is false.

The <IncludeRelatedContacts> element can be set to true for assignment rules for the Account record type only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
    <data:AssignmentRule>
. . .
      <data:IncludeRelatedContacts>false
      </data:IncludeRelatedContacts>
. . .
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

<IncludeRelatedOpportunities> specifies whether the opportunities that are linked to the account are assigned to the specified account owner and territory if the rule criteria are met (true), or the opportunities that are linked to the account are not assigned to the specified account owner and territory (false). The default value is false.

The <IncludeRelatedOpportunities> element can be set to true for assignment rules for the Account record type only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRuleGroup>
. . .
  <data:ListOfRule>
    <data:AssignmentRule>
. . .
      <data:IncludeRelatedOpportunites>false
      </data:IncludeRelatedOpportunites>
    </data:AssignmentRule>
. . .
  </data:ListOfRule>
. . .
</data:AssignmentRuleGroup>

Elements and Sections in the Assignment Rules Output File

The following table describes the elements and sections in the assignment rules XML output file.

Table Elements and Sections in the Assignment Rules XML File

Description Element or Section

The <AssignmentRule> section contains all of the details of one assignment rule.

<data:AssignmentRule>
. . .
</data:AssignmentRule>

<RecordType> contains the system name of the record type (object), which never changes.

<data:AssignmentRule>
  <data:RecordType>Account</data:RecordType>
. . .
</data:AssignmentRule>

<RuleGroupName> contains the name of the assignment rule group to which this rule belongs.

<data:AssignmentRule>
. . .
  <data:RuleGroupName>AcctTestGroup
  </data:RuleGroupName>
. . .
</data:AssignmentRule>

<RuleName> contains the name of the rule.

<data:AssignmentRule>
. . .
  <data:RuleName>AcctRule1</data:RuleName>
. . .
</data:AssignmentRule>

<Order> is the order number for the assignment rule within the rule group. It determines the order in which the assignment manager invokes a sequence of assignment rules. The rule numbered 1 is invoked first, followed by the rule numbered 2, and so on.

<data:AssignmentRule>
. . .
  <data:Order>1</data:Order>
. . .
</data:AssignmentRule>

<AssignTo> contains the User Sign In ID of the user to whom the record is assigned if the criteria on the rule are met. When the criteria on one rule are met, the record is assigned and subsequent rules are ignored.

<data:AssignmentRule>
. . .
  <data:AssignTo>EXAMPLECOMPANY/TESTUSER2
  </data:AssignTo>
. . .
</data:AssignmentRule>

The <SendEmailNotification> element specifies whether an email notification is sent to the user to whom the record is assigned (true) or an email notification is not sent to the user (false). The default value is true.

The <SendEmailNotification> element can be set to false for assignment rules for the Service Request record type only. This element is ignored for upsert requests for assignment rules for other record types.

Note: You cannot turn off the email notification for assignment rules for the Lead record type. No email notifications are sent for account and opportunity assignments, even if the <EmailNotification> element is set to true
<data:AssignmentRule>
. . .
  <data:SendEmailNotification>true
  </data:SendEmailNotification>
. . .
</data:AssignmentRule>

<AssignToTerritory> is the territory to which the record is assigned if the criteria on the rule are met.

The <AssignToTerritory> element is applicable for assignment rules in assignment rule groups for the Account and Opportunity record types only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:AssignToTerritory/>
. . .
</data:AssignmentRule>

<IncludeTeamAssignment> specifies whether the team members are assigned to the record (true), or the team members are not assigned to the record (false).

This element can be set to true for assignment rules in assignment rules for the Account and Opportunity record types only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:IncludeTeamAssignment>true
  </data:IncludeTeamAssignment>
. . .
</data:AssignmentRule>

<IncludeRelatedContacts> specifies whether the contacts that are linked to the account are assigned to the specified account owner and territory if the rule criteria are met (true), or the contacts that are linked to the account are not assigned to the specified account owner and territory (false). The default value is false.

The <IncludeRelatedContacts> can be set to true for assignment rules for the Account record type only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:IncludeRelatedContacts>true
  </data:IncludeRelatedContacts>
. . .
</data:AssignmentRule>

<IncludeRelatedOpportunities> specifies whether the opportunities that are linked to an account are assigned to the specified account owner and territory if the rule criteria are met (true), or the opportunities that are linked to the account are not assigned to the specified account owner and territory (false). The default value is false.

The<IncludeRelatedOpportunities> element can be set to true for assignment rules for the Account record type only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:IncludeRelatedOpportunities>true
  </data:IncludeRelatedOpportunities>
. . .
</data:AssignmentRule>

The <ListofTeam> section contains details of the team members who share ownership of the assigned records.

Team members can be added to assignment rules for the Account and Opportunity record types only. The <ListofTeam> section is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
   . . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

The <Team> section contains details of one of the team members who share ownership of the assigned records.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
    <data:Team>
. . .
    </data:Team>
. . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

<User> contains the first and last name of the user.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
    <data:Team>
      <data:User>Test User</data:User>
. . .
    </data:Team>
. . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

<Role> contains the role of the team member. This element is read-only and is ignored for upsert requests.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
    <data:Team>
. . .
      <data:Role>TestRole</data:Role>
. . .
    </data:Team>
. . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

<AccountAccess> specifies the level of access that the user has to the account records that are assigned by this rule, and to the account records that are linked to the account. The <AccountAccess> element is applicable for assignment rules for the Account record type only. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
    <data:Team>
. . .
      <data:AccountAccess>Edit
      </data:AccountAccess>
. . .
    </data:Team>
. . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

<ContactAccess> specifies the level of access that the user has to the contact records that are linked to the account records that are assigned by this rule. The <ContactAccess> element is applicable for assignment rules for the Account record type only, and is applicable only if the <IncludeRelatedContacts> element is set to true for the rule. This element is ignored for upsert requests for assignment rules for other record types.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
    <data:Team>
. . .
      <data:ContactAccess>Full
      </data:ContactAccess>
. . .
    </data:Team>
. . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

<OpportunityAccess> specifies the level of access that the user has to the opportunity records that are assigned by this rule, and to the opportunity records that are linked to the opportunity. In addition, if the <IncludeRelatedOpportunities> element is set to true for the rule, then the <OpportunityAccess> element specifies the level of access that the user has to the opportunity records that are linked to the account records that are assigned by this role.

<data:AssignmentRule>
. . .
  <data:ListofTeam>
    <data:Team>
. . .
      <data:OpportunityAccess>ReadOnly
      </data:OpportunityAccess>
    </data:Team>
. . .
  </data:ListofTeam>
. . .
</data:AssignmentRule>

The <ListofRuleCriteria> section contain details of the criteria for the assignment rule. You can specify multiple criteria for one rule.

<data:AssignmentRule>
. . .
  <data:ListOfRuleCriteria>
. . .
  </data:ListOfRuleCriteria>
</data:AssignmentRule>

The <Rule> section contains the details of one rule criterion.

<data:AssignmentRule>
. . .
  <data:ListOfRuleCriteria>
    <data:Rule>
. . .
    </data:Rule>
. . .
  </data:ListOfRuleCriteria>
</data:AssignmentRule>

<Field> contains the name of the field that is to be evaluated.

<data:AssignmentRule>
. . .
  <data:ListOfRuleCriteria>
    <data:Rule>
      <data:Field>Account Type</data:Field>
. . .
    </data:Rule>
. . .
  </data:ListOfRuleCriteria>
</data:AssignmentRule>

<Condition> specifies the condition that must be satisfied to meet the criterion.

<data:AssignmentRule>
. . .
  <data:ListOfRuleCriteria>
    <data:Rule>
. . .
      <data:Condition>Contains all values
      </data:Condition>
. . .
    </data:Rule>
. . .
  </data:ListOfRuleCriteria>
</data:AssignmentRule>

<Value> contains the value for the criterion.

<data:AssignmentRule>
. . .
  <data:ListOfRuleCriteria>
    <data:Rule>
 . . .
      <data:Value>Competitor</data:Value>
. . .
    </data:Rule>
. . .
  </data:ListOfRuleCriteria>
</data:AssignmentRule>

<Sequence> specifies the sequence of the criterion on the rule. This field is read-only and is ignored for upsert requests.

<data:AssignmentRule>
. . .
  <data:ListOfRuleCriteria>
    <data:Rule>
. . .
      <data:Sequence>1000</data:Sequence>
    </data:Rule>
. . .
  </data:ListOfRuleCriteria>
</data:AssignmentRule>

Migrating Assignment Rule Groups

The following topics provide examples of how to use the Oracle Migration Tool On Demand client with assignment rule groups:

Note: Back up your configuration data and all other relevant data before running the Oracle Migration Tool On Demand client.

    Extracting a Single Assignment Rule Group

    This topic describes how to extract a single assignment rule group from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment. The output from the extract is saved to a file and directory as follows:

    migration tool install/repository/AssignmentRuleGroup/RecordType/AssignmentRuleGroupName.xml
    

    Syntax

    The following is the syntax for using the Oracle Migration Tool On Demand client to extract a single assignment rule group:

    migrationtool -u UserID -s ServerURL Read AssignmentRuleGroup [SystemNameOfObject] RuleGroupName
    

    where:

    • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

    • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

    • SystemNameOfObject is the system name of the object (record type) to which the assignment rule groups applies, for example, Account. The system names for the record types are listed in System Names for Record Types. If you do not specify the record type, then you must specify an empty value for the SystemNameOfObect parameter. An empty value is specified as a set of double quotation marks ("").

      Note: Assignment rule groups are supported only for the Account, Lead, Opportunity, and Service Request record types.
    • RuleGroupName is the name of the rule group that you want to extract.

    Example of Extracting a Single Assignment Rule Group

    The following is an example of extracting a single assignment rule group:

    migrationtool -u UserID -s ServerURL Read AssignmentRuleGroup Account "My Account Assignment Rule Group"
    
    Note: If the object name contains spaces, then it must be enclosed with quotation marks. Similarly, if the rule group name contains spaces, then it must be enclosed with quotation marks.

      Extracting All Assignment Rule Groups for a Single Object

      This topic describes how to extract all assignment rule groups for a single object from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment.

      Syntax

      The following is the syntax for using the Oracle Migration Tool On Demand client to extract all assignment rule groups for a single object:

      migrationtool -u UserID -s ServerURL Read AssignmentRuleGroup SystemNameOfObject
      

      where:

      • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

      • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

      • SystemNameOfObject is the system name of the object (record type) to which the assignment rule groups applies, for example, Account. The system names for the record types are listed in System Names for Record Types.

      Note: Assignment rule groups are supported only for the Account, Lead, Opportunity, and Service Request record types.

      Example of Extracting All Assignment Rule Groups for a Single Object

      The following is an example of extracting all assignment rule groups for a single object:

      migrationtool -u UserID -s ServerURL Read AssignmentRuleGroup Account
      Note: If the object name contains spaces, then it must be enclosed with quotation marks.

        Extracting All Assignment Rule Groups

        This topic describes how to extract all assignment rule groups from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment.

        Syntax

        The following is the syntax for using the Oracle Migration Tool On Demand client to extract all assignment rule groups:

        migrationtool -u UserID -s ServerURL ReadAll AssignmentRuleGroup

        where:

        • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

        • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

        Note: The Oracle Migration Tool On Demand client requests your Oracle CRM On Demand password, which can be redirected (using the pipe command) to the client program from standard input; that is, from a file, from the command line, or from another program.

          Updating or Inserting an Assignment Rule Group

          This topic describes how to use the Upsert command to update an assignment rule group (if it exists) or insert an assignment rule group (if it does not exist) in your Oracle CRM On Demand environment; that is, a customer test environment or production environment. For the purposes of the Oracle Migration Tool On Demand client, this is known as an Upsert operation.

          About the Upsert Operation

          The Upsert command inserts or updates an assignment rule group based on the user key: <RecordType> and <RuleGroupName>.

          Oracle CRM On Demand attempts to locate the rule group based on the user key. If a match is located, then the rule group is updated. If Oracle CRM On Demand cannot locate a rule group based on the user key, then a new rule group is created.

          For the rules specified in the input file for the assignment rule group (if any rules are specified), the Upsert command inserts or updates the assignment rules based on either of the following user keys:

          • User key 1. <RuleGroupName> and <RecordType> and <RuleName>.

          • User key 2. <RuleGroupName> and <RecordType> and <Order>.

          The <RuleName> and <Order> elements are child elements of the <AssignmentRule> element.

          When you use the Upsert AssignmentRuleGroup command to update an existing rule group, Oracle CRM On Demand attempts to locate the rules that are specified in the input file based on the user keys. If a match is located, then the rule is updated. If a match is located for both user keys, then the match located for user key 1 takes precedence. If Oracle CRM On Demand cannot locate an assignment rule based on the user keys, then a new rule is created.

          When you run the Upsert command, if the assignment rule group already exists, then the existing assignment rules in the rule group are updated, and new assignment rules for the rule group are inserted. Existing rules in the rule group that are not included in the input file are not affected.

          Syntax

          The following is the syntax for using the Oracle Migration Tool On Demand client to update an assignment rule group (if it exists) or to insert a new assignment rule group (if it does not exist):

          migrationtool -u UserID -s ServerURL Upsert AssignmentRuleGroup AssignmentRuleGroupXML

          where:

          • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

          • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

          • AssignmentRuleGroupXML is the fully qualified path name of the assignment rule group XML file, for example:

            C:\My Files\MyAssignmentRuleGroup.xml
            
          Note: The Oracle Migration Tool On Demand client requests your Oracle CRM On Demand password, which can be redirected (by using the pipe command) to the client program from standard input; that is, from a file, from the command line, or from another program.

          Example of Updating or Inserting an Assignment Rule Group

          The following is an example of updating an assignment rule group (if it exists) or inserting an assignment rule group (if it does not exist) in your Oracle CRM On Demand server:

          migrationtool -u UserID -s ServerURL Upsert AssignmentRuleGroup "C:\Oracle Migration Tool On Demand\repository\AssignmentRuleGroup\Account\My AssignmentRuleGroup.xml"
          
          Note: Quotation marks are required only if the path or file name contains spaces.

            Migrating Assignment Rules

            The following topics provide examples of how to use the Oracle Migration Tool On Demand client with assignment rules:

            Note: Back up your configuration data and all other relevant data before running the Oracle Migration Tool On Demand client.

              Extracting a Single Assignment Rule

              This topic describes how to extract a single assignment rule from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment. The output from the extract is saved to a file and directory as follows:

              migration tool install/repository/AssignmentRule/RecordType/AssignmentRuleGroupName/AssignmentRuleName.xml
              

              Syntax

              The following is the syntax for using the Oracle Migration Tool On Demand client to extract a specific assignment rule:

              migrationtool -u UserID -s ServerURL Read AssignmentRule [SystemNameOfObject] [RuleGroupName] RuleName
              

              where:

              • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

              • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

              • SystemNameOfObject is the system name of the object (record type) to which the assignment rule applies, for example, Account. The system names for the record types are listed in System Names for Record Types. If you do not specify the record type, then you must specify an empty value for the SystemNameOfObect parameter. An empty value is specified as a set of double quotation marks ("").

                Note: Assignment rule groups are supported only for the Account, Lead, Opportunity, and Service Request record types.
              • RuleGroupName is the name of the rule group to which the rule belongs. If you do not specify the rule group name, then you must specify an empty value for the RuleGroupName parameter. An empty value is specified as a set of double quotation marks ("").

              • RuleName is the name of the rule that you want to extract.

              Note: The Oracle Migration Tool On Demand client requests your Oracle CRM On Demand password, which can be redirected (by using the pipe command) to the client program from standard input; that is, from a file, from the command line, or from another program.

              Example of Extracting a Single Assignment Rule

              The following is an example of extracting a specific assignment rule:

              migrationtool -u UserID -s ServerURL Read AssignmentRule Account "My Assignment Rule Group" MyAssignmentRule
              
              Note: If the object name contains spaces, then it must be enclosed with quotation marks. Similarly, if the assignment rule group name contains spaces, then it must be enclosed with quotation marks, and if the assignment rule name contains spaces, then it must be enclosed with quotation marks.

                Extracting All Assignment Rules for a Single Rule Group

                This topic describes how to extract all assignment rules for a single rule group from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment.

                Syntax

                The following is the syntax for using the Oracle Migration Tool On Demand client to extract all assignment rules for a single rule group:

                migrationtool -u UserID -s ServerURL Read AssignmentRule [SystemNameOfObject] RuleGroupName

                where:

                • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

                • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

                • SystemNameOfObject is the system name of the object (record type) to which the assignment rules apply, for example, Account. The system names for the record types are listed in System Names for Record Types. If you do not specify the record type, then you must specify an empty value for the SystemNameOfObect parameter. An empty value is specified as a set of double quotation marks ("").

                • RuleGroupName is the name of the rule group to which the rule belongs.

                  Note: Assignment rules are supported only for the Account, Lead, Opportunity, and Service Request record types.

                Example of Extracting All Assignment Rules for a Single Rule Group

                The following is an example of extracting all assignment rules for a single rule group:

                migrationtool -u UserID -s ServerURL Read AssignmentRule Account "My Assignment Rule Group"
                
                Note: If the object name contains spaces, then it must be enclosed with quotation marks. Similarly, if the assignment rule group name contains spaces, then it must be enclosed with quotation marks.

                  Extracting All Assignment Rules for a Single Object

                  This topic describes how to extract all assignment rules for a single object from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment.

                  Syntax

                  The following is the syntax for using the Oracle Migration Tool On Demand client to extract all assignment rules for a single object:

                  migrationtool -u UserID -s ServerURL Read AssignmentRule SystemNameOfObject
                  

                  where:

                  • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

                  • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

                  • SystemNameOfObject is the system name of the object (record type) to which the assignment rules apply, for example, Account. The system names for the record types are listed in System Names for Record Types.

                  Note: Assignment rules are supported only for the Account, Lead, Opportunity, and Service Request record types.

                  Example of Extracting All Assignment Rules for a Single Object

                  The following is an example of extracting all assignment rules for a single object:

                  migrationtool -u UserID -s ServerURL Read AssignmentRule Account
                  Note: If the object name contains spaces, then it must be enclosed with quotation marks.

                    Extracting All Assignment Rules

                    This topic describes how to extract all assignment rules from the Oracle CRM On Demand server for your environment; that is, a customer test environment or production environment.

                    Syntax

                    The following is the syntax for using the Oracle Migration Tool On Demand client to extract all assignment rules:

                    migrationtool -u UserID -s ServerURL ReadAll AssignmentRule

                    where:

                    • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

                    • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

                    Note: The Oracle Migration Tool On Demand client requests your Oracle CRM On Demand password, which can be redirected (using the pipe command) to the client program from standard input; that is, from a file, from the command line, or from another program.

                      Updating or Inserting an Assignment Rule

                      This topic describes how to use the Upsert command to update an assignment rule (if it exists) or insert an assignment rule (if it does not exist) in your Oracle CRM On Demand environment; that is, a customer test environment or production environment. For the purposes of the Oracle Migration Tool On Demand client, this is known as an Upsert operation.

                      About the Upsert Operation

                      The Upsert command updates an assignment rule based on either of the following user keys:

                      • User key 1. <RuleGroupName> and <RecordType> and <RuleName>.

                      • User key 2. <RuleGroupName> and <RecordType> and <Order>.

                      Oracle CRM On Demand attempts to locate the rules that are specified in the input file based on the user keys. If a match is located, then the rule is updated. If a match is located for both user keys, then the match located for user key 1 takes precedence. If Oracle CRM On Demand cannot locate an assignment rule based on the user keys, then a new rule is created.

                      For each rule, the Upsert command inserts or updates rule criteria and team information based on the following user keys:

                      • Rule criteria. The <Sequence> element, which is a child element of the <ListofRuleCriteria> element.

                      • Team information. The <User> element, which is a child element of the <Team> element.

                      Note: You must migrate the assignment rule group to which an assignment rule belongs before you migrate the assignment rule.

                      Syntax

                      The following is the syntax for using the Oracle Migration Tool On Demand client to update a specific assignment rule (if it exists) or to insert an assignment rule (if it does not exist):

                      migrationtool -u UserID -s ServerURL Upsert AssignmentRule AssignmentRuleXML

                      where:

                      • UserID is the user sign-in ID that has the appropriate privileges to run the Oracle Migration Tool On Demand client commands.

                      • ServerURL is the URL for the Oracle CRM On Demand server where your company resides.

                      • AssignmentRuleXML is the fully qualified path name of the assignment rule XML file, for example:

                        C:\My Files\My Assignment Rule.xml
                        
                      Note: The Oracle Migration Tool On Demand client requests your Oracle CRM On Demand password, which can be redirected (by using the pipe command) to the client program from standard input; that is, from a file, from the command line, or from another program.

                      Example of Updating or Inserting an Assignment Rule

                      The following is an example of updating an assignment rule (if it exists) or inserting an assignment rule (if it does not exist) in your Oracle CRM On Demand server:

                      migrationtool -u UserID -s ServerURL Upsert AssignmentRule "C:\Oracle Migration Tool On Demand\repository\AssignmentRule\Account\MyAccountRuleGroup\My AssignmentRule1.xml"
                      
                      Note: Quotation marks are required only if the path or file name contains spaces.