IBM Books

API Reference

sqlurcon - Reconcile

Validates the references to files for the DATALINK data of a table. The table must be in Datalink_Reconcile_Pending state prior to invoking this utility. The rows for which the references to files cannot be established are put into the exception table, and modified in the input table.

Authorization

One of the following:

sysadm
sysctrl
sysmaint
dbadm
CONTROL privilege on the table.

Required Connection

Database

API Include File

sqlutil.h

C API Syntax



/* File: sqlutil.h */
/* API: Reconcile */
/* ... */
SQL_API_RC SQL_API_FN
  sqlurcon (
    char * pTableName,
    char * pExTableName,  /* NOTE: This parameter is not currently used. */
    char * DlfmServerName,
    char * reportFileName,
    void * pReserved,
    struct sqlca * pSqlca);
/* ... */

Generic API Syntax



/* File: sqlutil.h */
/* API: Reconcile */
/* ... */
SQL_API_RC SQL_API_FN
  sqlgrcon (
    unsigned short TableNameLen,
    char * pTableName,
    unsigned short ExTableNameLen,
    char * pExTableName,
    unsigned short DlfmServerNameLen,
    char * DlfmServerName,
    unsigned short reportFleNameLen,
    char * reportFileName,
    void * pReserved,
    struct sqlca * pSqlca);
/* ... */

API Parameters

TableNameLen
Input. A 2-byte unsigned integer representing the length in bytes of the table name.
pTableName
Input. The table on which reconciliation is to be performed. The fully qualified name or alias in the form: schema.tablename must be used. The schema is the user name under which the table was created.
ExTableNameLen
Input. A 2-byte unsigned integer representing the length in bytes of the exception table name.
pExTableName
Input. This parameter is not currently used, and should be set to zero.
DlfmServerNameLen
Input. A 2-byte unsigned integer representing the length in bytes of the DLFM server name.
DlfmServerName
Input. Specifies the DLFM server that was pre-configured for use with this database.
reportFileNameLen
Input. A 2-byte unsigned integer representing the length in bytes of the report file name.
reportFileName
Input. Specifies the file that will contain information about the files that are unlinked during reconciliation.
pReserved
Reserved for future use.
pSqlca
Output. A pointer to the sqlca structure. For more information about this structure, see SQLCA.

Usage Notes

During reconciliation, attempts are made to link files which exist according to the table data, but which do not exist according to the DLFM metadata, if no other conflict exists.

When the reconcile utility is invoked without specifying a DLFM server name, reconciliation is performed with respect to all DATALINK data in the table. If file references cannot be established, the violating rows are not deleted from the input table, but to ensure DATALINK file reference integrity, the offending DATALINK values are NULLed. If the column is defined as not NULLable, the URL part of the DATALINK value is replaced by a zero length URL (the comment part is untouched). At the end of processing, the table is taken out of Datalink_Reconcile_Pending state.

If a DLFM server is specified, reconciliation is done only with respect to this server. In this case, other servers are not contacted, even if they are present in the DATALINK data. At the end of reconciliation, the table is taken out of Datalink_Reconcile_Pending state only if the table data has no reference to other DLFM servers. If, after performing reconciliation with respect to one or more DLFM servers for a table, the integrity of DATALINK data in the table is certain, the table can be taken out of check pending state by issuing the SET CONSTRAINTS ... IMMEDIATE UNCHECKED statement.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]

[ DB2 List of Books | Search the DB2 Books ]