REPLACE profile command


This command replaces the contents of a migrate or baseline profile. If the profile already exists, this command removes the associated definitions, such as scope rules, change rules, and locations. This command creates a new migrate or baseline profile if the profile does not exist. Either include an existing profile to use for the scope rules or use the ADD SCOPE command to add scope rules to the profile definition.

You can use the REPLACE profile command in the batch profile JCL.

REPLACE MIGRATE PROFILE

This section describes REPLACE MIGRATE PROFILE syntax.

BatchProfile_replaceMigrateKeyword_SPE2210.png

Variable

Description

profileOwner.profileName

This variable defines the name of the migrate profile that you want to replace.

migrateType

This variable defines the type of migrate profile. Valid values are as follows:

Value

Description

OUTBOUND

OUTBOUND is the only valid value for migrate type in the batch profile process. The Analysis and Compare components use outbound migrate profiles to generate worklists or CDL files, or to specify objects. If you do not specify a migrate type, the batch profile process defaults to OUTBOUND. 

INBOUND

The batch process does not support INBOUND migrate profiles. The Import component uses inbound migrate profiles to make input from another system compatible with the receiving subsystem’s version of the application. 

blProfileOwner.blProfileName

This variable specifies a catalog baseline profile to define scope rules that select the Db2 objects to include in the migration. If you do not specify a baseline profile, you must specify scope rules for the outbound migrate profile.

comment

The comment is displayed or printed whenever the profile is used and can contain descriptive text about the profile. The maximum length of the comment is 255 characters. Any characters beyond the maximum are truncated.

Examples

The following examples illustrate the use of the REPLACE MIGRATE PROFILE command:

Examples

The following syntax replaces an outbound migrate profile, removing all the scope rules, change rules, and locations in the profile definition. Use the ADD-SCOPE-command to define scope rules for the profile.

REPLACE MIGRATE PROFILE MVSAMA.MPTEST1

The following syntax replaces an outbound migrate profile that uses a catalog baseline profile for its scope rules:

REPLACE MIGRATE PROFILE MVSAMA.MPTEST3 OUTBOUND BLPREF=MVSAMA.BPTEST1 

The following syntax replaces an existing migrate profile with a profile that references a baseline profile for the scope:

REPLACE MIGRATE PROFILE PROFCR.MPSAMP1
OUTBOUND BLPREF=PROFCR.BPTST1
REMARKS(MP replace with BLPREF)

REPLACE BASELINE PROFILE

This section describes REPLACE BASELINE PROFILE syntax.

BatchProfile_replaceBaselineKeyword_SPE2210.png

Variable

Description

profileOwner.profileName

This variable defines the name of the baseline profile that you want to replace.

baselineType

This variable defines the scope of the data structures when you create the baseline. Valid values are as follows:

Value

Description

CATALOG

A catalog baseline uses the data structures from the Db2 catalog. The catalog baseline profile can explicitly specify the scope rules or can reference the scope rules in an outbound migrate profile. If not specified, CATALOG is the default baseline type.

DDL

A DDL baseline uses the data structures from a DDL file or migrate-type worklist.

baselineTemplate

This variable specifies a template for the names of the baselines that are created using the profile. The template name must begin with an alphabetic character, cannot exceed 18 characters, and must contain either @@@@@@, @@@@@@@@, or ####:

  • @@@@@@ are replaced by the current date in the form YYMMDD.
  • @@@@@@@@ are replaced by the current date in the form YYYYMMDD.
  • #### are replaced by an ascending sequence of numbers.

migProfileOwner.migProfileName

This variable specifies an outbound migrate profile to use for scope rules in a catalog baseline. If you do not specify migrate profile, you must specify scope rules for the catalog baseline. In a DDL baseline, the DDL file or migrate-type worklist specifies the scope. 

DELETEAGE = value

This option specifies the minimum number of days to retain a baseline created with this profile. This option specifies to automatically delete baselines that are built with this profile that are older than the DELETEAGE value. To retain all of the completed baselines, specify zero for this option and the RETAINMAX option.

RETAINMAX = value

This option specifies the maximum number of baselines to retain that were created with this profile. To retain all of the completed baselines, specify zero for this option and the DELETEAGE option.

comment

The comment is displayed or printed whenever the profile is used and can contain descriptive text about the profile. The maximum length of the comment is 255 characters. Any characters beyond the maximum are truncated.

Examples

The following examples illustrate the use of the REPLACE BASELINE PROFILE command:

Example

The following syntax replaces a catalog baseline profile that uses an outbound migrate profile for its scope rules:

REPLACE BASELINE PROFILE MVSAMA.BPTEST3 CATALOG MIGPREF=MVSAMA.MPTEST1

The following syntax replaces a DDL baseline profile that defines a template for the baseline names.  It also specifies to retain the latest baseline created with this profile indefinitely or until another baseline is created with this profile.

REPLACE BASELINE PROFILE MVSAMA.BPTEST4 DDL BLTEMP=MVSAMA#### DELETEAGE=0 RETAINMAX=1 

Important

You can use only one method to delete baselines automatically for a profile. That is, you cannot use a nonzero value for both DELETEAGE and RETAINMAX in the same job.

The following syntax replaces an existing baseline profile with a profile that references a migrate profile for the scope and includes a DELETEAGE:

REPLACE BASELINE PROFILE PROFCR.BPCAT01 CATALOG
MIGPREF=PROFCR.MPSAMP3 DELETEAGE=10
REMARKS(CATALOG BP create MIGPREF DELETEAGE)

Example

The following example illustrates how to replace a DDL baseline profile that defines a template for the baseline names.  It also specifies to retain the latest baseline created with this profile indefinitely or until another baseline is created with this profile.

Important

You can use only one method to delete baselines automatically for a profile. That is, you cannot use a nonzero value for both DELETEAGE and RETAINMAX in the same job.


REPLACE BASELINE PROFILE MVSAMA.BPTEST4 DDL BLTEMP=MVSAMA#### DELETEAGE=0 RETAINMAX=1 

The following example illustrates how to replace an existing baseline profile with a profile that references a migrate profile for the scope and includes a DELETEAGE:

REPLACE BASELINE PROFILE PROFCR.BPCAT01 CATALOG
MIGPREF=PROFCR.MPSAMP3 DELETEAGE=10
REMARKS(CATALOG BP create MIGPREF DELETEAGE)

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*