Alter Partition

The MaxL alter partition statement helps you fix invalid or dangling Essbase partition references, by changing the authorized user who can connect to both cubes, or by changing application, cube, or host names in the event something was moved or renamed.

Syntax


Description of altpart.gif follows
Description of the illustration altpart.gif

Use alter partition to edit partitions in the following ways:

Keywords

...set connect

Change the user authorized to access the partitioned cubes.

...set hostname

Edit the partition definition to include the correct URL for the partition source cube, target cube, or both.

...set application as

Edit the partition definition to include a corrected application name. This is useful if one application name was changed; if both application names changed, the partition definition cannot be corrected and you must re-create it.

...set database as

Edit the partition definition to include a corrected cube name. This is useful if one cube name was changed; if both cube names changed, the partition definition cannot be corrected and you must re-create it.

...direction single

See Examples 2 and 5.

...direction all

See Examples 3, 4, and 6.

Notes

  • The first DBS-NAME is the local cube, and the second DBS-NAME is the remote cube.

  • Directing a partition to the remote site means the current cube is the source. Creating a partition from the remote site means the current cube is the target.

  • To change the authorized partition user, you must change the user for both partitioned cubes, as shown in Example 1.

  • If a partitioned host, application, or cube is renamed, the rename does not propagate to the partition definition, so you must use alter partition to change the name in the partition definition. You must give the old name and the new name. If both names were changed, the partition definition is not recoverable, and must be re-created. Exception: Host names can be updated on source and target, as shown in Example 4.

Example

Example 1 – Change Partition User

The following example changes the user authorized to access the partitioned cubes.

/* To change authorized partition user on target, log in to source & then use: */
       alter transparent partition app1.source to app2.target 
       set connect as newuser identified  by newpasswd;

/* To change authorized partition user on source, log in to target & then use: */
       alter transparent partition app2.target from app1.source 
       set connect as newuser identified  by newpasswd;

Example 2 – Update One Host Name for Target

In the following example, alter partition is used to fix a partition definition that became invalid when a URL changed and affected only one half of the partition definition (app2.target):

alter transparent partition app1.source to app2.target at "https://myserver1.example.com:9001/essbase/agent" 
     set hostname as "https://myserver2.example.com:9001/essbase/agent" instead of "https://myserver1.example.com:9001/essbase/agent" direction single;

where direction single indicates that only the target URL needs to be changed.

Example 3 – Update One Host Name for Source and Target

In the following example, alter partition is used to fix a partition definition that became invalid when one host-name change affected both the source and the target, because both applications were on the same host:

alter transparent partition app1.source to app1.target at "https://myserver2.example.com:9001/essbase/agent" 
     set hostname as "https://myserver2.example.com:9001/essbase/agent" instead of "https://myserver1.example.com:9001/essbase/agent" direction all;

where direction all indicates that the host-name change needs to be made on both the target and source halves of the partition definition.

Example 4 – Update Host Name for Source and Target

In the following example, alter partition is used to fix a partition definition that became invalid when target and source cubes that were on different hosts are both moved to the same new host:

alter transparent partition app1.target from app2.source set hostname as "https://myserver3.example.com:9001/essbase/agent" instead of "https://myserver1.example.com:9001/essbase/agent" direction all;

OR

alter transparent partition app1.target from app2.source set hostname as "https://myserver3.example.com:9001/essbase/agent" instead of "https://myserver2.example.com:9001/essbase/agent" direction all;

where direction all indicates that the host-name change needs to be made on both the target and source halves of the partition definition.

Example 5 – Update Source Application Name

In the following example, alter partition is used to fix a partition definition that became invalid when the source application name (oldAppName) changed to newAppName, and affected only one half of the partition definition:

alter transparent partition newAppName.source to app2.target  
    set application as newAppName instead of oldAppName direction single;

where direction single indicates that only one half of the partition definition needs to be corrected.

Note:

The old application name can be discovered by issuing the display partition statement prior to correcting the partition definition.

Example 6 – Update Application Name for Source and Target

In the following example, alter partition is used to fix a partition definition that became invalid when the source application name (oldAppName) changed to newAppName, and affected both halves of the partition definition because both partitioned cubes were on the same application:

alter transparent partition newAppName.source to newAppName.target  
     set application as newAppName instead of oldAppName direction all;

where direction single indicates both halves of the partition definition need to be corrected.