Setting CDT preference settings in text mode

About this task

You can manually configure preferences and parameter settings that determine the behavior of the comparison operation by editing the ydkprefs.xml.sample file and saving the file as ydkprefs.xml.

To configure Configuration Deployment Tool preference settings:

Procedure

  1. Rename the <INSTALL_DIR>/resources/ydkresources/ydkprefs.xml.sample file to ydkprefs.xml.
  2. In ydkprefs.xml, specify parameters for CDT preference elements. Table 1 describes the elements in ydkprefs.xml.
    Table 1. Configuration deployment tool preference settings
    Element Description
    <Settings> Element
    CustomEntityClass Specify the name of the class that should be invoked for deploying custom tables not handled by CDT.
    Note: If you don't want to use this field, set the value of this field to null. For example, CustomEntityClass="".
    MaxChangesToDisplay Specify the maximum number of differences to be displayed. The default display number is 100.
    Note: If you don't want to use this field, set the value of this field to null. For example, MaxChangesToDisplay="".
    ReportsDir Specify the absolute path where you want reports to be generated.
    Note: If you don't want to use this field, set the value of this field to null. For example, ReportsDir="".
    ValidateLockid Specify Y, if you want the system to detect conflict based on the expected Lockid of a record of the obtained changes from the source database against the current Lockid of the corresponding record in the target database.

    By default, it is set to N.

    ValidateOldValues Specify Y, if you want the system to detect conflict based on the expected old value of an attribute of a record of the obtained changes from the source database against the current value of the corresponding record in the target database.

    By default, it is set to Y.

    ValidateRecordExistsBeforeDelete Specify Y, if want the system to validate the record exists in the target database before it attempts to delete it. If the record is not there, the operation will be marked as a conflict.

    By default, it is set to Y.

    <SourceDatabases> Element
    Name Specify a logical database identifier. For the source, specify the database you want to copy data from. For the target, specify the database to write the data to.
    className Specify the class name of your database driver as follows:
    • If using Oracle, set to: oracle.jdbc.OracleDriver
    • If using DB2®, set to: com.ibm.db2.jcc.DB2Driver
    dbType Specify the type of database you are running. Enter it in all lower case, as shown:
    • For Oracle, specify oracle
    • For DB2, specify db2
    • For an XML datasource, specify xml
    folder If using an XML datasource, specify the complete path of the folder location for the XML files.
    Note: If the source database is a database schema, you must set the value of this attribute to null. For example, folder="".
    jdbcURL Specify the URL to connect to the database:
    • If using Oracle, set to: jdbc:oracle:thin:@<DatabaseServerHostname/IPaddress>:<TNSListenerPortNumber>:<DatabaseSID>.
    • If using DB2, set to: jdbc:db2://<Database Server Hostname>:<Port Number>/<Database name>.
    schema Specify the schema owner as follows:
    • If you are using Oracle or DB2 database, and the user you specify is different from the Sterling Selling and Fulfillment Foundation schema owner, specify the owner of the Sterling Selling and Fulfillment Foundation schema.
    Note: For Oracle and DB2 databases, leave this field blank if the schema name is same as the username.
    user Specify the user name associated with the database.
    <TargetDatabases> Element
    For Name, className, dbType, folder, jdbcURL, schema, and user attributes descriptions, see the <SourceDatabases> Element section in this table.
    httpurl Only applicable for the target database. Specify a URL for the application server whose data cache is to be refreshed after data is deployed into the target database. Use the syntax: http://<hostname/ip-address>:<port-number>/<Application>/interop/InteropHttpServlet, where <hostname/IP-address> is the server address where the application is running, <port-number> is the port on which the application is running, and <Application> is the name of the application; for example, smcfs.
    httpuser Specify the username associated with the application server whose data cache is to be refreshed after data is deployed into the target database.
    <SourceTargetPrefs> Element
    SourceDatabase Specify the name of the source database.
    TargetDatabase Specify the name of the target database.
    <Transformations> Element

    Tables and Columns that can be added or deleted.

    <Table> Element's Name Attribute Specify the name of the table on which you want to carry out the transformation. The syntax and case must match the name of the table used in the Sterling Selling and Fulfillment Foundation ERDs. Custom tables cannot be transformed. Choose the Details icon to specify a value.
    Note: If you don't want to use this field, set the value of this field to null. For example, Name="".
    <Column> Element's Name Attribute Specify the name of the column containing the data to be transformed. The syntax and case must match the name of the column used in the Sterling Selling and Fulfillment Foundation ERDs. Extended columns can be transformed. Choose the Details icon to specify a value.
    Note: If you don't want to use this field, set the value of this field to null. For example, Name="".
    <Transform> Element

    Define the transformation for this column. For each column, you can define one or more transformations. These transformations are applied to data in this column in sequential order. You can specify multiple transformations for each column, using the delete action to remove the parent element.

    Match Specify the pattern to search for in the source data. All matching occurrences of this pattern are replaced with the value specified in the Replace attribute. Choose the Details icon to specify a value.
    Replace Specify the value to replace the pattern with. Choose the Details icon to specify a value.
    XPath Conditional. If the column to be transformed contains non-XML data, you do not need to specify this XPath attribute. However, some configuration information in Sterling Selling and Fulfillment Foundation is stored as XML in the database.

    If the column to be transformed contains XML data, use this attribute to specify the location of the exact attribute to be transformed.

    Use the syntax: xml:/Configuration/Connection/Host/@IPAddress. Choose the Details icon to specify a value.

    <Ignore> Element
    <Table> Element's Name Attribute Specify any external configuration tables that you do not want the tool to deploy from the source to the target. Ignoring a table automatically ignores all dependent tables as well.
    Note: If you don't want to use this field, set the value of this field to null. For example, Name="".
    <AppendOnly> Element
    <Table> Element's Name Attribute Specify configuration table, if any, in which some rows maintain data that is external to Sterling Selling and Fulfillment Foundation. This prevents the data from being deleted during deployment. Specify that table and all of its dependent tables.
    Note: Rows that are maintained externally should never be present in your source database, since this can lead to unpredictable results.
    Note: If you don't want to use this field, set the value of this field to null. For example, Namer="".