19Migrating Dynamic Page Layouts

Migrating Dynamic Page Layouts

This chapter describes how to migrate dynamic page layouts using the command-line interface of the Oracle Migration Tool On Demand client. It contains the following topics:

Dynamic Page Layouts

Dynamic page layouts are page layouts that show different sets of fields for different records of the same record type, depending on the picklist value that you select in a certain field on the record.

The following table describes the Oracle Migration Tool On Demand client commands used with dynamic page layouts. For more information about running these commands, see Migrating Dynamic Page Layouts.

Table Commands Used with Dynamic Page Layouts in Oracle Migration Tool On Demand

Command Description

[-sortspec "[Name [sortorder]][, Value [sortorder]]"] Read DynamicLayout SystemNameOfObject

This command extracts the configuration data for the dynamic page layouts for a specific record type (object).

SystemNameOfObject is the system name of the record type. The system names for the record types are listed in System Names for Record Types.

The optional sortspec parameter allows you to sort the dynamic layouts by dynamic layout name, and to sort the picklist values within a dynamic layout by picklist value name.

Name is the sort field for the dynamic layouts.

Value is the sort field for the picklist values within a dynamic layout.

If you do not specify Name, then the dynamic layouts are listed in no specific order. If you do not specify Value, then the picklist values for each dynamic layout are listed in no specific order.

The valid values for sortorder are:

  • ASC for sorting in ascending order.

  • DESC for sorting in descending order.

If you specify Name but you do not specify the sort order for the names, then the sort order is ascending by default. Similarly, if you specify Value but you do not specify the sort order for the values, then the sort order is ascending by default.

[-sortspec "[Name [sortorder]][, Value [sortorder]]"] ReadAll DynamicLayout

This command extracts the configuration data for the dynamic page layouts for all objects.

For information about the optional sortspec parameter, see the description of the Read command.

Upsert DynamicLayout DynamicLayoutXML

This command updates or inserts a dynamic page layout, as required.

Privileges Required for Migrating Dynamic Page Layouts

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

  • For the Read and ReadAll command: Enable Web Services Access.

  • For the Upsert command: Enable Web Services Access and Customize Application - Manage Dynamic Layout.

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

Elements and Sections in the Dynamic Page Layout XML Output File

The following table describes the elements and sections in the dynamic page layout XML output file.

Table Elements and Sections in the Dynamic Page Layout XML File

Description Element or Section

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

<data:ObjectName>Opportunity</data:ObjectName> 

<DrivingPicklist> contains the name of the dynamic page layout driving picklist. For more information about driving picklists, see Oracle CRM On Demand Online Help.

<data:DrivingPicklist>Sales Type</data:DrivingPicklist>

The <ListOfDynamicLayouts> section contains the details of the dynamic page layouts for the object.

<data:ListOfDynamicLayouts>
. . .
</data:ListOfDynamicLayouts>

The <DynamicLayout> section contains the details of one dynamic page layout.

<data:ListOfDynamicLayouts>
  <data:DynamicLayout>
. . .
  </data:DynamicLayout>
. . .
</data:ListOfDynamicLayouts>

<Name> contains the name of the dynamic page layout.

<data:ListOfDynamicLayouts>
  <data:DynamicLayout>
    <data:Name>dynamic</data:Name>
. . .
  </data:DynamicLayout>
. . .
</data:ListOfDynamicLayouts>

<DefaultLayout> contains the name of the default page layout with which the driving picklist values are associated.

<data:ListOfDynamicLayouts>
  <data:DynamicLayout>
. . .
    <data:DefaultLayout>Opportunity Page
     Standard Layout</data:DefaultLayout>
. . .
  </data:DynamicLayout>
. . .
</data:ListOfDynamicLayouts>

<ModifiedBy> contains the name of the user who last updated the dynamic page layout.

<data:ListOfDynamicLayouts>
  <data:DynamicLayout>
. . .
    <data:ModifiedBy>sales10</data:ModifiedBy>
. . .
  </data:DynamicLayout>
. . .
</data:ListOfDynamicLayouts>

<Description> contains the description of the dynamic page layout.

<data:ListOfDynamicLayouts>
  <data:DynamicLayout>
. . .
    <data:Description>Dynamic Layout Description
    </data:Description>
. . .
  </data:DynamicLayout>
. . .
</data:ListOfDynamicLayouts>

The <ListofPicklistValueMapping> section contains the mappings of the driving picklist values to the page layouts:

  • <Value> contains the driving picklist value.

  • <AssignedLayout> contains the name of the page layout that is displayed when the driving picklist value is selected.

<data:ListOfDynamicLayouts>
  <data:DynamicLayout>
. . .
    <data:ListOfPicklistValueMapping>
      <data:DrivingPicklist>
        <data:Value>New Business</data:Value>
        <data:AssignedLayout>test2</data:AssignedLayout>
      </data:DrivingPicklist>
    </data:ListOfPicklistValueMapping>
. . .
  </data:DynamicLayout>
. . .
</data:ListOfDynamicLayouts>

Migrating Dynamic Page Layouts

The following topics provide examples of how to use the Oracle Migration Tool On Demand client to migrate dynamic page layout field information:

Extracting Dynamic Page Layouts for a Single Object

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

Note: Users require the Enable Web Services Access privilege to run the Read command.

Syntax

The following is the syntax for using the Oracle Migration Tool On Demand client to extract the dynamic page layouts for a single object:

migrationtool -u UserID -s ServerURL Read DynamicLayout 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) for which you want to read a set of dynamic page layouts, for example, Account. The system names for the record types are listed in System Names for Record Types.

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.

Examples of Extracting Dynamic Page Layouts for a Single Object

The following is an example of extracting the dynamic page layouts for the Opportunity record type:

migrationtool -u UserID -s ServerURL Read DynamicLayout Opportunity

In the following example, the dynamic layouts for the Account record are extracted, with the output sorted as follows:

  • The dynamic layouts are sorted by dynamic layout name in ascending order.

  • The picklist values within each dynamic layout are sorted by picklist value name in descending order.

migrationtool -u UserID -s ServerURL -sortspec "Name ASC,Value DESC" Read DynamicLayout Account

Extracting Dynamic Page Layouts for All Objects

This topic describes how to extract all dynamic page layouts from your Oracle CRM On Demand environment (customer test environment or production).

Syntax

The following is the syntax for using the Oracle Migration Tool On Demand client to extract all dynamic page layouts:

migrationtool -u UserID -s ServerURL ReadAll DynamicLayout

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.

Examples of Extracting Dynamic Page Layouts for All Objects

The following is an example of extracting all dynamic page layouts from your Oracle CRM On Demand server:

migrationtool -u UserID -s ServerURL ReadAll DynamicLayout

In the following example, the output of the ReadAll command is sorted as follows:

  • The dynamic layouts for each record type are sorted by dynamic layout name in ascending order.

  • The picklist values within each dynamic layout are sorted by picklist value name in descending order.

migrationtool -u UserID -s ServerURL -sortspec "Name ASC, Value DESC" ReadAll DynamicLayout

Updating or Inserting Dynamic Page Layouts (Upsert)

This topic describes how to update dynamic page layout information for a single object (if it exists) or insert this information (if it does not exist) in your Oracle CRM On Demand environment (customer test environment or production).

Syntax

The following is the syntax for using the Oracle Migration Tool On Demand client to update dynamic page layout information (if it exists) for a single object or insert this information (if it does not exist):

migrationtool -u UserID -s ServerURL Upsert DynamicLayout DynamicLayoutXML 

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.

  • DynamicLayoutXML is the fully qualified path name of the dynamic page layout XML file, for example:

    C:\My Files\DynamicLayout.xml
    

Example of Updating or Inserting a Dynamic Page Layout

The following is an example of updating a dynamic page layout (if it exists) or inserting this information (if it does not exist) in your Oracle CRM On Demand server:

migrationtool -u UserID -s ServerURL Upsert DynamicLayout "C:\My Files\DynamicLayout.xml"
Note: Quotation marks are required only if the name contains spaces.