Scalable Database Server, HiRDB Version 8 Command Reference

[Contents][Index][Back][Next]

13.1 Overview

The integrity check utility (pdconstck) performs integrity checking and manipulates (sets or releases) the check pending status on tables for which referential constraints or check constraints have been defined.

Organization of this section
(1) Prerequisites
(2) Authorization identifier during execution of pdconstck

(1) Prerequisites

(a) Operating conditions

Table 13-1 describes the prerequisites for executing pdconstck.

Table 13-1 Prerequisites for executing pdconstck

Item Prerequisites
Execution privilege A user with the DBA privilege or the subject table's owner can execute the utility.
RDAREA status For details about the relationship between pdconstck and the status of an RDAREA to be processed, see C. RDAREA Status During Command Execution.
Concurrent execution Only one instance of pdconstck can be executed on the same table at the same time. If multiple instances of pdconstck are executed concurrently, deadlock may occur between the subject table's TABLE resource type (resource type 0002) and DICT resource type (resource type 3005).
Multiple instances of pdconstck can be executed concurrently as long as there is no duplication among the target tables. However, when the check pending status is changed, the utility is placed in lock-release wait status.
Maximum number of utilities that can be executed concurrently The maximum number of instances of pdconstcks that can be executed concurrently is equal to the value of the pd_max_users operand/2.
Number of resources Because pdconstck locks the target table and a referenced table that is referenced by a foreign key, you must pay attention to the following values in the system definition:
  • Number of base tables that can be accessed concurrently
    In the pd_max_access_tables operand in the system definition, specify a value that is at least (number of foreign keys for the target table + 1).
  • Sum of the number of locked tables and the number of RDAREAs for which UNTIL DISCONNECT is specified per server
    In the pd_lck_until_disconnect_cnt operand in the system definition, specify a value that is at least the value of X in the following formula:
    X = (2 + number of foreign keys for the target table + number of RDAREAs that store the target table + total number of RDAREAs that store the table whose primary key is referenced by the foreign keys)
  • Lock pool size per server
    In the pd_lck_pool_size operand in the system definition, specify a value that is at least [Figure]Y[Figure]x[Figure].
In a HiRDB/Single Server:
Y = 209 + A + f + (a + c + (d [Figure] b))
In a HiRDB/Parallel Server:
[Figure] Dictionary server
Y = 209 + A + (a + c + (d [Figure] b))
[Figure] Front-end server
Y = 2 + f
[Figure] Back-end server
Y = (d [Figure] b)

Legend:
a: Number of table storage RDAREAs
b: Number of index storage RDAREAs
c: Number of LOB column storage RDAREAs
d: Number of indexes
f: Number of plug-ins defined for the target table and the table whose primary key is referenced by foreign keys
x: 6 for 32-bit mode HiRDB, 4 for 64-bit mode HiRDB
A: MAX (number of columns in the table, number of indexes for the table, number of table storage RDAREAs, number of foreign keys for the table, number of check constraints for the table)
Change of check pending status Executing pdconstck changes the check pending status, regardless of the specification of the pd_check_pending operand in the system definition.
(b) Operating environment

Table 13-2 describes the operating environment for pdconstck.

Table 13-2 Operating environment for pdconstck

Item Operating environment
HiRDB environment Location of command execution Execute pdconstck at the server machine that contains the single server, or where the system manager is located.
Server status When you execute pdconstck, the following server(s) must be running:

In a HiRDB/Single Server: Single server

In a HiRDB/Parallel Server: Dictionary server, front-end server, and back-end server (in the case of multiple front-end servers, at least one of them must be running)
PDDIR environment variable In the PDDIR environment variable, set the absolute path name of the HiRDB directory.
PDCONFPATH environment variable In the PDCONFPATH environment variable, set the absolute path name of the directory that stores the HiRDB system definition files.
OS environment LANG environment variable In the LANG environment variable, set the value appropriate for the character encoding specified in the pdntenv command. For details about LANG, see the manual HiRDB Version 8 UAP Development Guide.
File and directory specified in the -o option Access privileges must have been granted to the user who executes pdconstck.
If the -o option was omitted, access privileges must be granted in the same manner; otherwise, the system assumes that files are to be created in the HiRDB-installation-drive\tmp directory. The path name is not case sensitive. Therefore, if a path name that differs only in case from an existing path name is specified, that existing file will be overwritten.

(2) Authorization identifier during execution of pdconstck

When you execute pdconstck, you can specify the authorization identifier used to connect to HiRDB as well as the authorization identifiers for the target table and the constraint name. Table 13-3 lists the authorization identifier used to connect to HiRDB and the authorization identifiers for the target table and constraint name.

Table 13-3 Authorization identifier used to connect to HiRDB and authorization identifiers for the target table and constraint name

Specification condition Connection with HiRDB Auth identifier for the target table or constraint name
Auth identifier used to connect to HiRDB (-u option) PDUSER environment variable Auth identifier for target table or constraint name (-t or -c option) Auth identifier Password
Auth identifier Password
Specified Specified Specified Specified Authorization identifier specified in the -u option Entered in response to a message* Authorization identifier specified in the -t or -c option
Not specified Authorization identifier specified in the -u option
Omitted Specified Authorization identifier specified in the -t or -c option
Not specified Authorization identifier specified in the -u option
PDUSER environment variable omitted Specified Authorization identifier specified in the -t or -c option
Not specified Authorization identifier specified in the -u option
Not specified Specified Specified Specified Authorization identifier specified in the PDUSER environment variable Password specified in the PDUSER environment variable Authorization identifier specified in the -t or -c option
Not specified Authorization identifier specified in PDUSER environment variable
Omitted Specified Omitted Authorization identifier specified in the -t or -c option
Not specified Authorization identifier specified in PDUSER environment variable
PDUSER environment variable omitted Specified User name (authorization identifier) in the login window Entered in response to a message* Authorization identifier specified in the -t or -c option
Not specified User name (authorization identifier) in the login window

Legend:
Auth: Authorization

* A message requesting entry of a password is displayed. Enter the appropriate password as the response to this message. If NULL is entered as the response, the system assumes that no password was set.